Problems with 'Launch <doc> with <app>'
sarahr at genesearch.com.au
Mon Apr 19 22:52:39 CDT 2004
> However, prompted by your advice that the problem is due to OS X's
> ".app" extension on application bundles, and remembering that bundles
> actually folders, I opened the bundle and found the actual application
> file I was looking for. I then made a note of all the folders
> it (remembering to add ".app" for the bundle folder) and used this to
> create my launch command:
> launch "/Users/jonathan/Documents/Test.txt" with \
> "/Application Folders/BBEdit 7.0/BBEdit.app/Contents/MacOS/BBEdit"
Does "/Application Folders/BBEdit 7.0/BBEdit.app" work?
I have tried "/Applications/TextEdit.app" and it works fine.
> And this is what happened:
> If BBEdit wasn't running, the document would open, as expected.
> However, if I had already launched BBEdit from the Finder, the document
> would open, but BEHIND Revolution!
> Strangely, if I had already launched BBEdit from Rev, I would get an
> "Process already open" and nothing would happen.
> Most surprising of all (to me)... if I then quit BBEdit and tried the
> command again, I would STILL get the message "Process already open"!
> It seems like Rev doesn't bother checking again with the System, it
> I suppose a workaround could be to get Rev to quit the app first, then
> launch it (again), but...
> 1. What command would I use for that? "Kill"? It appears that this only
> works for processes opened with the "open process" command.
You can does this one in Transcript. Rev seems to keep a list of
processes that it started and doesn't let go even if the program has
finished. If the program is still running, this command doesn't
actually stop it, it just clears Rev's brain enough to allow you to use
if the openProcesses contains appPath then
kill process appPath
where appPath is the full location of your app as discussed above.
> 2. If I managed to do it (with AppleScript?) I could have the problem
> an unsaved document bringing up a dialog box, possibly behind Rev's
> windows, that would bring things to a halt.
Since "kill process" doesn't actually stop the application, this is not
More information about the use-livecode