EF BB BF     UTF-8
FE FF          UTF-16/UCS-2, little endian windows
FF FE          UTF-16/UCS-2, big endian
FF FE 00 00  UFT-32/UCS-4, little endian
00 00 FE FF  UFT-32/UCS-4, big-endian

EX)

USHORT Test_Short = 0xfeff;

CString Test_String="";

Test_String.Format(L"%d", Test_Num);

WriteFile(hFile, &Test_Short, 2, &dwNumWrite, NULL);

WriteFile(hFile, Test_String, lstrlen(test)*2, &dwNumWrite, NULL);

'개발자료 > MFC&WIN32' 카테고리의 다른 글

SetLocalTime  (1) 2011.02.16
형변환  (0) 2011.02.13
COPYDATASTRUCT  (0) 2011.02.11
CFile Class  (0) 2011.02.11
WriteFile 이어쓰기  (0) 2011.02.11
Posted by 구룡포과메기
,