Re: Entourage : Returning info from multiple new messages
Re: Entourage : Returning info from multiple new messages
- Subject: Re: Entourage : Returning info from multiple new messages
- From: Jay Louvion <email@hidden>
- Date: Tue, 16 Aug 2005 12:57:00 +0200
le 16/08/05 1:33, Barry Wainwright à email@hidden est réputé(e) avoir
écrit :
>> I now need to know how to handle multiple incoming messages or multiple
>> selections (those would be for the testing, essentially): how different is it
>> from the following script:
>>
>> tell application "Finder"
>> set startupdisk to startup disk as string
>> end tell
>> tell application "Microsoft Entourage"
>> set ATD to AppleScript's text item delimiters
>> set AppleScript's text item delimiters to " "
>> set image_source to startupdisk & "DVDimages:" as alias
>> set save_target to startupdisk & "Users:ptilu:DVDimages:" as alias
> Change this line:
>> set theMsg to item 1 of (get current messages)
> to:
>
> Repeat with theMsg in (get current messages)
>
>> set {theSubject, theContent} to theMsg's {subject, content}
>> set eventcode to text item 1 of theSubject
>> set ordernum to text item 2 of theSubject
>> set MailNr to text item 3 of theSubject as integer
>> set AppleScript's text item delimiters to ""
>> set shortnum to (items 3 thru end of ordernum) as string
>> if items 1 thru 2 of ordernum is not {"L", "G"} then
>> beep 6
>> return
>> end if
>> set theLink to {}
>> if MailNr is 5 then
>> set BeginLink to
>> "http://www.apple.com/bin/document?format=delivery&orderid="
>> set shortnum to items 3 thru end of ordernum as string
>> set theLink to BeginLink & shortnum
>> end if
> Remove this line:
>> end tell
>
>> set AppleScript's text item delimiters to ATD
>> if the theLink is not {} then
>> set theDownload to (startupdisk & "incoming.pdf" as text)
>> tell application "URL Access Scripting"
>> download theLink to file theDownload
>> end tell
>> tell application "Finder"
>> print theDownload
>> move file theDownload to trash
>> end tell
>> end if
> And add these:
>
> End repeat
> End tell
>
Wonderful !
How do I ask the script to bypass any messages that don't comply but
continue the repeat ? "skip themsg" ? Ignore the missive ?
Thanks for your insight,
J.
Jay Louvion
Studio Casagrande
3, rue Müller-Brun
1208 Geneva
T+4122 840 3272
F+4122 840 3271
skypeme:
jaylouvion
www.studiocasagrande.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden