osax, load script question
osax, load script question
- Subject: osax, load script question
- From: richard brosnahan <email@hidden>
- Date: Fri, 31 Aug 2001 08:04:49 -0400
Hi scripting geniuses,
I've searched the archives, as I expect this question has been answered. I
didn't have any luck. Excuse me if this has been asked and answered before.
I have a main script that does a lot of stuff. It uses IE and BBEdit to
accomplish a number of tasks. I have a bunch of other small scripts that
just call the main script with a parameter. The main script is stored in the
scripting additions folder and I use "load script" to load it. When I
execute the smaller scripts within Script Debugger, Smile, Script Editor,
etc., they dutifully load the library script and the whole thing runs like
clockwork. When running inside a script editor, it takes about 3 seconds to
run one cycle.
What I want is to take the script editor out of the equation. I first tried
Drag Thing. I just attach the smaller scripts to buttons on a palette.
Sometimes it works, most times I hit the button and wait FOR-EV-ER for the
thing to start executing (45 seconds waiting, 3 seconds to execute). I don't
know what's up with that.
Then I tried OneClick. The editor for OneClick is a bear. It blows up all
the time. When I finally get the script installed and hit the button,
nothing happens. Click all day long and nothing.
So now I move the scripts over to FinderPop. OK, aliases to the scripts. Now
the scripts execute right away, BUT an osax call within the script is just
completely ignored. <sigh>
I've not tried saving the smaller scripts as applets, because the launch
time would probably be unacceptable. It's very important that these scripts
execute quickly.
I'm guessing this is a memory thing. Where do the standalone scripts
scavenge memory when running from FinderPop or Drag Thing? My scripts really
don't need much memory for variables and such, but perhaps the sheer size of
the library is a problem. Even so, It's not THAT big. Say maybe 8k.
I'm puzzled.
Thanks for your generous help.
===============================
Richard Brosnahan
Editor in Chief
Broznews
http://broznews.com/