• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Entourage : Returning info from multiple new messages
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Entourage : Returning info from multiple new messages


  • Subject: Entourage : Returning info from multiple new messages
  • From: Jay Louvion <email@hidden>
  • Date: Tue, 16 Aug 2005 00:49:10 +0200

Title: Entourage : Returning info from multiple new messages

I have made good progress in a script that handles incoming messages, printing them if their subject meets the right requirements, searching the disk for a disk image if the content of the message contains certain text.

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
   set theMsg to item 1 of (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
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

Thanks in advance,

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

  • Follow-Ups:
    • Re: Entourage : Returning info from multiple new messages
      • From: Barry Wainwright <email@hidden>
  • Prev by Date: Re: GUI Scripting - Print/Save PDF As Postscript
  • Next by Date: Re: GUI Scripting - Print/Save PDF As Postscript
  • Previous by thread: [OT] Smile List...?
  • Next by thread: Re: Entourage : Returning info from multiple new messages
  • Index(es):
    • Date
    • Thread