Title: Re: Script to archive Notes
Here is a script that will do it:

tell application "Microsoft Entourage"
    set theNotes to notes
    set AppleScript's text item delimiters to {return}
    set notesList to {}
    repeat with aNote in theNotes
        set thisNote to {name of aNote, content of aNote}
        set theCats to category of aNote
        if theCats ≠ {} then
            set catList to "Categories: "
            repeat with aCat in theCats
                set catList to catList & name of aCat
            end repeat
            set end of thisNote to catList as text
        end if
        set theProjs to project list of aNote
        if theProjs ≠ {} then
            set projList to "Projects: "
            repeat with aProj in theProjs
                set projList to projList & name of aProj
            end repeat
            copy projList as text to end of thisNote
        end if
        copy thisNote as text to end of notesList
    end repeat
end tell
set AppleScript's text item delimiters to {return & "==========================" & return & return}


set filePath to ((path to desktop) as text) & "Notes Export.txt"
try
    set outFile to open for access filePath with write permission
on error errnum
    try
        close access outFile
    end try
    display dialog "An error Occurred - error number: " & errnum
    return
end try
write (notesList as text) to outFile starting at 0
close access outFile

--
Barry Wainwright
Microsoft MVP (see http://mvp.support.microsoft.com for details)
Seen the All-New Entourage Help Pages? - Check them out:
        <http://www.entourage.mvps.org/>


> From: Paul Berkowitz <[EMAIL PROTECTED]>
> Reply-To: "Entourage:mac Talk" <[email protected]>
> Date: Wed, 31 Aug 2005 09:03:16 -0700
> To: Entourage Mac Talk <[email protected]>
> Conversation: Script to archive Notes
> Subject: Re: Script to archive Notes
>
> On 8/31/05 6:44 AM, "Bob Salsburg" <[EMAIL PROTECTED]> wrote:
>
>> I've searched most of the usual sites MacScripter, etc. looking for a
>> script to archive Notes, say to a TextEdit file. Has any one seen one?
>
> My "Export-Import Entourage" shareware script, which is in that shortlist at
> the top of
>  
>  MacScripter.net   <http://macscripter.net/scriptbuilders/>
>
> exports notes, among other things, to a tab-delimited text file.
>
> --
> Paul Berkowitz
> MVP MacOffice
> Entourage FAQ Page: <http://www.entourage.mvps.org/faq/index.html>
> AppleScripts for Entourage: <http://macscripter.net/scriptbuilders/>
>
> PLEASE always state which version of Microsoft Office you are using -
> **2004**, X  or 2001. It's often impossible to answer your questions
> otherwise.
>
>
> --
> To unsubscribe:                     
> <mailto:[EMAIL PROTECTED]>
> archives:       
> <http://www.mail-archive.com/entourage-talk%40lists.letterrip.com/>
> old-archive:       
> <http://www.mail-archive.com/entourage-talk%40lists.boingo.com/>
>

Reply via email to