how to access string table of .lib file from an EXE
C / C++ / MFC
1
Posts
1
Posters
0
Views
1
Watching
-
Hello all, I linked a lib file say sss.lib with myapp.exe. when I tried to access a string from a string table of sss.lib, I got '1814' error msg. The code is { #if defined _ATL HINSTANCE hInst = _Module.GetModuleInstance(); #else HINSTANCE hInst = GetModuleHandle(NULL); #endif TCHAR buff[1025]; GetModuleFileName(hInst,buff,sizeof(buff)/sizeof(TCHAR)); unsigned nID = 101; DWORD dw; LoadString(hInst,nID,buff,sizeof(buff)/sizeof(TCHAR)); if(!LoadString(hInst,nID,buff,sizeof(buff)/sizeof(TCHAR))) dw = GetLastError(); AfxMessageBox(buff); } I don't know how to pull off this.Can you halp me? Thanks, GAN