Hello, List -- On 12/12/08 10:22 AM (local time), mike sanders
(<mike...@mac.com>) wrote:

> Tried everything to find "findofficeversion" but no success can you
> provide the link.

Guess it's no longer there. Here's the script -- just compile it in script
editor, then put it in your Entourage menu Items Folder, quit and relaunch
Entourage, and it should be accessible from the Script menu at the top of
your screen:

property appList : {"Microsoft Entourage", "Microsoft Excel", "Microsoft
Word", 
"Microsoft Powerpoint", "Microsoft Messenger.app", "Microsoft Component
Plugin", 
"Junk E-Mail Protection"}
property IDList : {"OPIM", "XCEL", "MSWD", "PPT3", "MSNS", "MMcp", "MSOF"}
property sysVersion : "Mac OS Version Unknown" -- Saved between runs

tell application "Finder"
    set officeFolder to (container of application file id "MSWD") as Unicode
text
end tell

set msg to ""
repeat with i from 1 to (count appList)
    set theApp to item i of appList
    set itsID to item i of IDList
    if theApp is "Microsoft Component Plugin" or theApp is "Junk E-Mail
Protection" 
    then -- Not really an app; a library
        -- So we cannot use application file id to locate it
        try -- Usual location
            set theFile to alias (officeFolder & "Office:" & theApp)
            set mcpDate to my getinfo(theFile)
            set msg to msg & return & mcpDate
        on error
            try -- Possible alternate
                set theFile to officeFolder & theApp
                set mcpDate to my getinfo(theFile)
                set msg to msg & return & mcpDate
            on error
                my doErr(theApp)
            end try
        end try
        if theApp is "Microsoft Component Plugin" then set lastUp to mcpDate
    else -- Let the user move the apps anywhere
        tell application "Finder"
            set theFile to (application file id itsID) as alias
        end tell
        try
            set msg to msg & return & my getinfo(theFile)
        on error
            my doErr(theApp)
        end try
    end if
end repeat
set oldDelims to AppleScript's text item delimiters
set AppleScript's text item delimiters to {":"}
set lastUp to text item 2 of lastUp
set AppleScript's text item delimiters to oldDelims
set msg to "Last update applied: " & lastUp & return & msg
-- Find system version
do shell script "system_profiler SPSoftwareDataType"
set report to every paragraph of result
repeat with aLine in report
    if aLine contains "System Version" then
        set oldDelims to AppleScript's text item delimiters
        set AppleScript's text item delimiters to {":"}
        set sysVersion to text item 2 of aLine
        set sysVersion to text 2 thru -1 of sysVersion -- trim leading space
        set AppleScript's text item delimiters to oldDelims
        exit repeat
    end if
end repeat

set msg to msg & return & sysVersion
display dialog msg buttons {"Copy to Clipboard", "Exit"}
if button returned of result is "Copy to Clipboard" then
    set the clipboard to msg
    return
end if


on getinfo(xfile)
    set x to info for xfile
    return (name of x) & ": " & x's short version
end getinfo

on doErr(theApp)
    display dialog theApp & " was not found."
end doErr
 

Reply via email to