Strange problem
Strange problem
- Subject: Strange problem
- From: Steve Mills <email@hidden>
- Date: Fri, 30 Jul 2004 08:25:30 -0500
One of the scripts we ship with our app wasn't working on ONE of our
tech support person's OS9 machine. Here is the part in question:
property pClientName : "FavFontsPalette" --User pref client identifier.
property pFontListID : "FontList" --Font list user pref ID.
property pDefaultFonts : {"Helvetica Regular", "Times Regular"}
on run
tell application "MultiAd Creator Pro"
try
set fontList to (get user preference from client pClientName with ID
pFontListID)
on error err
set fontList to pDefaultFonts
end try
if fontList is {} then
set fontList to pDefaultFonts
end if
end tell
end run
When she ran it, it returned an error on the "if fontList is {} then"
line, saying that fontList wasn't defined. After having her try many
things, what ended up working was the addition of the line "local
fontList" at the top of the run handler. Does anybody see a reason why
it would NOT work on one OS9 machine, and why that would fix it?
Also strange; when I compiled the script in Script Debugger with
debugging turned on, it complained that there was code outside the run
handler. There isn't, except for the property definitions, and I'm sure
that is legal to have outside a run handler. Ain't it?
Steve Mills
Drummer, Mac geek
http://sjmills5.home.mchsi.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.