누군가 메시지 상자에 szFileName을 출력하는 방법을 알려주실 수 있습니까?TCHAR 및 문자열 연결을 사용하는 C++ messagebox
//Retrieve the path to the data.dat in the same dir as our app.dll is located
TCHAR szFileName[MAX_PATH+1];
GetModuleFileName(_Module.m_hInst, szFileName, MAX_PATH+1);
StrCpy(PathFindFileName(szFileName), _T("data.dat"));
FILE *file =fopen(szFileName,"rb");
if (file)
{
fseek(file,iFirstByteToReadPos, SEEK_SET);
fread(bytes,sizeof(unsigned char), iLenCompressedBytes, file);
fclose(file);
}
else
{
MessageBox(NULL, szFileName + " not found", NULL, MB_OK);
DebugBreak();
}
MessageBox (NULL, (tstring (szFileName) + "찾을 수 없음"). c_str(), NULL, MB_OK); ? – qPCR4vir