Mail Script to remove AUGD from Subject
Mail Script to remove AUGD from Subject
- Subject: Mail Script to remove AUGD from Subject
- From: Geoff WALLACE <email@hidden>
- Date: Sun, 11 Jan 2009 14:45:13 +1100
- Thread-topic: Mail Script to remove AUGD from Subject
Hello All,
Barry Wainwright provided this script for Ent 2008.
"tell application "Microsoft Entourage"
set currentMessages to the current messages
repeat with theMsg in the currentMessages
set str to the subject of theMsg
if str begins with "AUGD:" then
set str to text 6 thru -1 of str
try
repeat until first character of str is not " "
set str to text 2 thru -1 of str
end repeat
on error
-- str is empty
set str to "<No Subject"
end try
set subject of theMsg to str
end if
end repeat
end tell"
Wanted to try it in the Apple Mail Program on OS X 10.5.6.
Simple, change "Microsoft Entourage" to "Mail" in the 2nd line, I thought?
On doing this and trying to get the script to compile, get an error message
as follows
"Syntax Error
Expected end of line but found plural class name."
Is the syntax required for the Apple Mail program different to that required
for the Apple Mail Program?
--
Do you own or use an Apple Macintosh Computer?
If so at some time you will need the macfixer
<http://macfixer.com.au> Mob: 0412 056 033 Ph: 61 3 9893 1677
Geoff WALLACE
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden