lua-users home
lua-l archive

RE: Have a trouble when running Lua in MSVC8

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


I have been using Lua with VS2005 with no problems. Did you build the Lua library using VS2005 as well? I don't know if that would make a difference or not!
-----Original Message-----
From: lua-bounces@bazar2.conectiva.com.br [mailto:lua-bounces@bazar2.conectiva.com.br]On Behalf Of Nguyen Dang Quang
Sent: 13 June 2006 15:34
To: lua@bazar2.conectiva.com.br
Subject: Have a trouble when running Lua in MSVC8

Hi,

I have just port my application from MSVC6 to MSVC8 (Microsoft Visual Studio 2005). In the past, my application ran well but now it raise application error. At the following code At the second lua_pcall

if(luaL_loadfile(L,rule_path.c_str()) != 0 || lua_pcall(L, 0, 0, 0))

{

pi->m_current_processed_size = pi->m_current_size;

pi->m_total_processed_size += pi->m_current_size;

MessageBox(NULL,lua_tostring(L, -1),"Error executing the Script",MB_OK);

}

else//run the main function

{

//push the parameters onto the stack

lua_settop(L,0);

lua_getglobal(L, "main"); // function to be called

if (lua_pcall(L, 0 , 1, 0) != 0) //Khong argument, 1 result, khong co ham xu ly loi

{

MessageBox(NULL,lua_tostring(L, -1),"Error executing the Script",MB_OK);

}

}

Can lua 5.1 run well on MSVC8???

Help me please!!


AltStyle によって変換されたページ (->オリジナル) /