-
-
未解决
[求助]写入文件乱码,不知怎么解决
-
发表于:
2019-6-27 00:35
2474
-
#include <Windows.h>
int _tmain(int argc, _TCHAR* argv[])
{
TCHAR FileName[MAX_PATH];
HANDLE FileHandle;
lstrcpy(FileName,L"D:\\你好.txt");
FileHandle = CreateFile(FileName,GENERIC_WRITE,FILE_SHARE_WRITE,NULL,
CREATE_ALWAYS,FILE_ATTRIBUTE_NORMAL,NULL);
TCHAR Wbuffer[MAX_PATH] = L"你好";
DWORD nWrite;
WriteFile(FileHandle,Wbuffer,MAX_PATH,&nWrite,NULL);
}
[招生]科锐逆向工程师培训(2024年11月15日实地,远程教学同时开班, 第51期)