lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Jeff,
I have never used Wscript and know nothing about it.
Anyway, I tried it almost exactly as you suggested:

Function test()
  local vb="test.vbs"
  local f=io.open(vb)
  f:write("WScript.Sleep(1000)\n")
  f:close()
  for i=1,10 do
    msgbox("Waiting")
    io.flush()
    os.execute(vb)
  end
end

However, nothing happened when running test()...?

-----Original Message-----
From: lua-bounces@bazar2.conectiva.com.br
[mailto:lua-bounces@bazar2.conectiva.com.br] On Behalf Of Jeff Pohlmeyer
Sent: Wednesday, March 12, 2008 12:26 AM
To: Lua list
Subject: Re: NEWBIE Question: LUA wait() function?

local vb="test.vbs"
local f=io.open(vb)
f:write("WScript.Sleep(1000)\n")
f:close()
for i=1,10 do
print("Waiting")
io.flush()
os.execute(vb)
end