lua-users home
lua-l archive

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


>How can i execute a simple piece of lua code  from another lua script?

I'm not sure what you mean. If script A wants to run script B, try dofile"B"
inside A. If A wants to run a function defined in B, first dofile"B" before
or while running A and then call the function.

If you want to run Lua code stored in a string, use loadstring(s)() (or
dostring(s), in Lua 4.0).
--lhf