Re: System version as number (on non-US systems)
Re: System version as number (on non-US systems)
- Subject: Re: System version as number (on non-US systems)
- From: Harald E Brandt <email@hidden>
- Date: Mon, 16 Sep 2002 22:33:04 +0200
+--> Kai Edwards wrote 02-09-16:
try
tell application "Finder" to set {x, y} to {"", computer "sysv"}
on error number -1708 -- event not handled (no AS 1.6 commands in Classic)
set {x, y} to {"", 4096}
end try
+-
Precisely this error is what I asked on this list just a few days ago
with meager response. You say that this simply is because AS 1.6
can't handle it. I guess I will handle it the same way, even though
it is ugly to do so. I would like to know if you know if it can be
circumvented? Here is what I wanted to do and what I asked:
In a classic script app, I need to know the sysv attribute,
regardless whether it is running under 8.6, 9.x or Classic Env under
OS X.
However, doing:
computer "sysv"
or
system attribute "sysv"
in the applet does not work in Classic Env with AppleScript 1.6,
unless one previously has run the same thing in OS X directly.
Something gets "exercised" after it has been run in OS X so that it
also works in Classic.
Since the app is for distribution, upgrading AS is no option.
If the user has just logged in, and Classic has been started, how on
earth can I get the 'sysv', i.e the gestalt, in a classic script
application? I have already tried with and without Finder, even
pointing to the precis location of both the OS X Finder and OS 9
Finder, have also tried System Events, ... it just doesn't work for a
script app compiled for Classic! (unless it is already "exercised"
natively in OS X)
(PS: If you test it yourself (with AS 1.6), you have to first log out
and then log in again to get a "clean" envrionment, since, as I said
above, the first execution in the OS X environment of system
attribute will make it work also in Classic. But I need the script
app to work directly in Classic.)
__________________________BragIt___________________________
Harald E Brandt email@hidden
http://bragit.com
_______________________________________________
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.