How to prevent a stack from loading twice (in Linux)
Jan Schenkel
janschenkel at yahoo.com
Sat May 23 03:57:14 EDT 2009
--- On Sat, 5/23/09, Peter Alcibiades <palcibiades-first at yahoo.co.uk> wrote:
> From: Peter Alcibiades <palcibiades-first at yahoo.co.uk>
> Subject: Re: How to prevent a stack from loading twice (in Linux)
> To: use-revolution at lists.runrev.com
> Date: Saturday, May 23, 2009, 12:37 AM
>
> Ken, the problem is, they can start a second copy of the
> app when one copy of
> it is already running. But the stack script contains
> the following:
>
> on reloadStack
> close this stack
> end reloadStack
>
> So should not that cause it to check and see if it is
> already running, and
> if so quit? I also have tried with just
>
> on reloadStack
> end reloadStack
>
> But the second copy loads in either case.
>
> What I want to happen is that if someone tries to start the
> app when it is
> already running, for it to fail and not start. Maybe
> give an error message,
> but that's not essential.
>
> Peter
>
The 'reloadStack' message is only sent within the same application, when you attempt to load an already loaded stack.
Are you looking for the 'relaunch' message instead? Unless the docs are outdated, this will only work on Windows - and shouldn't be a problem on MacOSX anyway.
Jan Schenkel
=====
Quartam Reports & PDF Library for Revolution
<http://www.quartam.com>
=====
"As we grow older, we grow both wiser and more foolish at the same time." (La Rochefoucauld)
More information about the use-livecode
mailing list