Copy and pasting email addresses always inserts ‘mailto:email@email.com’ in the address field

How can the "mailto" be removed. We do this function over a hundred times in a day and this adds effort every time we need a simple solution for this to delete the mailto portion with copy. They must be a simple way to simply copy the email address only.... Pease respond.

Posted on Aug 7, 2020 6:37 AM

Reply
Question marked as Top-ranking reply

Posted on Aug 7, 2020 8:15 AM

If Barney's solution still isn't there for you, then here is a brief AppleScript that strips the mailto: prefix from the mail address:




  1. Launch Script Editor from Dock : Launchpad : Other.
  2. Copy/paste the following AppleScript code into the Script Editor
    1. Click the hammer (compile) button
    2. Click the Run button
    3. Copy/paste the mail address into the first dialog as shown in the above screen capture
  3. You can save the AppleScript as Format: Application to your Desktop and double-click it to run.


Code


-- email_addr.applescript

-- strip mailto: string from web mail address and present selectable address in dialog
use scripting additions

set orig_address to text returned of (display dialog "Enter source email address:" & return & "(e.g. mailto:magoo@example.com)" default answer "")

if orig_address contains "mailto:" then
	display dialog (do shell script "sed -e 's/^mailto://' <<<" & orig_address)
else
	display dialog "mail address already in expected format" giving up after 15
end if
return



2 replies
Question marked as Top-ranking reply

Aug 7, 2020 8:15 AM in response to Msacco1

If Barney's solution still isn't there for you, then here is a brief AppleScript that strips the mailto: prefix from the mail address:




  1. Launch Script Editor from Dock : Launchpad : Other.
  2. Copy/paste the following AppleScript code into the Script Editor
    1. Click the hammer (compile) button
    2. Click the Run button
    3. Copy/paste the mail address into the first dialog as shown in the above screen capture
  3. You can save the AppleScript as Format: Application to your Desktop and double-click it to run.


Code


-- email_addr.applescript

-- strip mailto: string from web mail address and present selectable address in dialog
use scripting additions

set orig_address to text returned of (display dialog "Enter source email address:" & return & "(e.g. mailto:magoo@example.com)" default answer "")

if orig_address contains "mailto:" then
	display dialog (do shell script "sed -e 's/^mailto://' <<<" & orig_address)
else
	display dialog "mail address already in expected format" giving up after 15
end if
return



This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Copy and pasting email addresses always inserts ‘mailto:email@email.com’ in the address field

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.