You need to initialize the Lua libraries here; otherwise, for example, the print() function won't be available. luaL_openlibs(ud);
luaL_openlibs(ud);
Thanks Eric, it worked :) Lloyd ______________________________________ Scanned and protected by Email scanner