[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: NEWBIE Question: LUA wait() function?
- From: "Rolf" <rb@...>
- Date: Wed, 12 Mar 2008 01:51:34 -0700
Maybe I am naively trying to do something that is not possible (I have very
limited "programming" experience).
The whole idea was to have the script periodically check (e.g. every 10 min)
for certain things in the database, and if conditions were satisfied, then
However, at the same time, I need to be able to use the program. Maybe this
is simply not possible. The wait function may simply lock the program as you
and others have suggested.
[mailto:firstname.lastname@example.org] On Behalf Of steve donovan
Sent: Wednesday, March 12, 2008 1:41 AM
To: Lua list
Subject: Re: NEWBIE Question: LUA wait() function?
This is the famous 'black box' problem with os.execute on Windows. The
only way to get around it is a special version of execute (like I do
with SciTE). But in that case, you have to be able to dynamically load
extensions anyway, and could pull in the Win32 Sleep function.
The question is, does this application export its Lua symbols? Or,
alternatively, does it link in Lua dynamically? (typically if there's
a lua51.dll or something like that). In that case, I can help you with
Although, having to _wait_ in a script seems awkward. Depending how
this app's threading works, this would lock things up totally. Does
this app have some kind of callback mechanism?
On Wed, Mar 12, 2008 at 10:22 AM, Rolf <email@example.com> wrote:
> I downloaded MSN sleep program here:
> then tried:
> function test()
> for i=1,3 do
> os.execute("sleep.exe 5")
> This seemed to work, except that I got a cmd window that opened and