Applescript adding %0A when opening URL from Mail
Hi there,
I'm trying to have Mail open a url, using a Rule that opens an Applescript, whenever I email said URL to myself. It works 95% perfect, except that it adds an unnecessary %0A to the end of the string any time it opens the URL, rendering the URL useless. How can I fix this?
The script I'm using is as follows:
using terms from application "Mail"
on perform mail action with messages theMessages for rule Torrent
tell application "Mail"
repeat with theMessage in theMessages
set theText to content of theMessage
set the clipboard to theText
end repeat
end tell
open location theText
end perform mail action with messages
end using terms from
I'm trying to have Mail open a url, using a Rule that opens an Applescript, whenever I email said URL to myself. It works 95% perfect, except that it adds an unnecessary %0A to the end of the string any time it opens the URL, rendering the URL useless. How can I fix this?
The script I'm using is as follows:
using terms from application "Mail"
on perform mail action with messages theMessages for rule Torrent
tell application "Mail"
repeat with theMessage in theMessages
set theText to content of theMessage
set the clipboard to theText
end repeat
end tell
open location theText
end perform mail action with messages
end using terms from
MacBook Pro, Mac OS X (10.5.8)