Re: Return Current OS
Re: Return Current OS
- Subject: Re: Return Current OS
- From: David Glass <email@hidden>
- Date: Wed, 20 Nov 2002 11:35:20 -0800
On 11/20/02 8:09, "Sgt. Pepper" <email@hidden> wrote:
>
Hello,
>
Can someone please help me with this syntax. I am writing a script
>
in which I need to determine the OS of the mac that the script is
>
running. I have tried everything I could think of and all I was able
>
to do was to get Apple System Profiler to return a Unicode Text Doc.
>
Here's a brief example of what I'm looking to do:
>
>
tell some app
>
get current OS
>
if result is "10.x" then
>
do OS X stuff
>
else
>
do OS 9 stuff
>
end if
>
end tell
>
My initial thought would be to do something like this:
try
some basic OS X command perhaps 'do shell script'
set OS flag to X
on error
must be OS 9
set OS flag to 9
end try
This gets more complicated if you want to check for more OS versions.
--
David Glass
email@hidden
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.