Scope Problem on Standalones
dburgun at dsl.pipex.com
Mon Nov 28 08:45:23 CST 2005
>>Bu according to the documentation, the path returned should be the
>>path to the real application, e.g.
>>Have I got this wrong?
>I think so. My understanding is that the app. is the bundle folder,
>as this is what the user sees as the app.
The thing is that, I could test for that, but what is stranger is that:
>Upon further inspection, I found that after :
> function LoadGlobalStacks
> local myStackFIlePathName
> local myStackFIlePath
> local myGlobalStackFilePathName
>put the filename of this stack into myStackFIlePathName
>put myStackFIlePathName into myStackFIlePath
>set itemDelimiter to :/"
>delete item -1 of myStackFIlePath
>set itemDelimiter to ","
>Has been run, myStackFIlePathName is equal to myStackFIlePathName,
>in other words the last item has NOT been deleted! I changed it to:
>put empty into item -1 of myStackFIlePath
>But this doesn't work either!
>I am testing this using answer dialogs since I can't run the
>debugger in the standalone and it works fine in the IDE.
>This an additional problem to the filename of the stack being
>inconsistent with the current stack. Why should a simple delete
>statement work under the IDE but not in Standalone mode?
So, it looks like simple delete and put statements are not working in
>Have you tried effective filename to locate the stack?
Yes, tried effective filename too
From the RunRev Online Documentation for file name of stack property:
Cross-platform note: On OS X systems, standalone applications are
stored as application bundles. A bundle behaves like a file but is
actually a folder, and the main stack of a standalone application is
inside this folder. The filename of stack property reports the
location of the application inside the bundle, not the bundle's
location. For example, if the bundle's file path is
"/Volumes/Disk/MyApp.app/", the filename of the application's main
stack might be "/Volumes/Disk/MyApp.app/Contents/MacOS/MyApp".
So, either there is a bug in RunRev or a Bug in the doumentation!
Anyway with *any* ideas of how to track this down however crazy it
may seem, please do let me know. I have managed to get an extension
on my deadline til Wednesday, but this just seems completely
unsoveable at the moment. If you can't tell the folder that the
current .rev file is running in when in a standalone, then I really
don't know what to do.
All the Best
More information about the use-livecode