Click here to Skip to main content
15,894,955 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Is learning win32 only learning functions in dll? Pin
Waldermort26-Aug-06 22:01
Waldermort26-Aug-06 22:01 
GeneralRe: Is learning win32 only learning functions in dll? Pin
Christian Graus26-Aug-06 22:06
protectorChristian Graus26-Aug-06 22:06 
GeneralRe: Is learning win32 only learning functions in dll? Pin
Waldermort26-Aug-06 22:14
Waldermort26-Aug-06 22:14 
GeneralRe: Is learning win32 only learning functions in dll? Pin
Andy Moore27-Aug-06 10:08
Andy Moore27-Aug-06 10:08 
GeneralRe: Is learning win32 only learning functions in dll? Pin
Christian Graus27-Aug-06 12:05
protectorChristian Graus27-Aug-06 12:05 
QuestionCreating Vista Style Menus and controls on XP and Windows 2000 Pin
wildbird198126-Aug-06 13:39
wildbird198126-Aug-06 13:39 
AnswerRe: Creating Vista Style Menus and controls on XP and Windows 2000 Pin
Hamid_RT3-Sep-06 9:04
Hamid_RT3-Sep-06 9:04 
QuestionWIN32 Console application colour ? Pin
James Laing26-Aug-06 12:14
James Laing26-Aug-06 12:14 
AnswerRe: WIN32 Console application colour ? Pin
Waldermort26-Aug-06 12:30
Waldermort26-Aug-06 12:30 
GeneralRe: WIN32 Console application colour ? Pin
James Laing26-Aug-06 12:35
James Laing26-Aug-06 12:35 
GeneralRe: WIN32 Console application colour ? Pin
James Brown27-Aug-06 4:26
James Brown27-Aug-06 4:26 
GeneralRe: WIN32 Console application colour ? Pin
James Laing28-Aug-06 1:44
James Laing28-Aug-06 1:44 
GeneralRe: WIN32 Console application colour ? Pin
James Brown28-Aug-06 2:35
James Brown28-Aug-06 2:35 
GeneralRe: WIN32 Console application colour ? Pin
James Laing28-Aug-06 3:54
James Laing28-Aug-06 3:54 
GeneralRe: WIN32 Console application colour ? Pin
James Brown28-Aug-06 4:13
James Brown28-Aug-06 4:13 
GeneralRe: WIN32 Console application colour ? Pin
James Laing28-Aug-06 9:50
James Laing28-Aug-06 9:50 
GeneralRe: WIN32 Console application colour ? Pin
James Brown28-Aug-06 10:39
James Brown28-Aug-06 10:39 
GeneralRe: WIN32 Console application colour ? Pin
James Laing28-Aug-06 11:41
James Laing28-Aug-06 11:41 
GeneralRe: WIN32 Console application colour ? Pin
Laing,James28-Aug-06 11:59
Laing,James28-Aug-06 11:59 
QuestionI hate Unicode!! Pin
Waldermort26-Aug-06 10:24
Waldermort26-Aug-06 10:24 
Why does it have to be so complex? I'm still trying to convert my code but I have ran into a brick wall. I'm reading UTF16 encoded strings from a byte array, most of these strings are Chinese simplified. So for a MBCS I use this

WideCharToMultiByte(936/* GB_2312 */,0,(unsigned short *)data,length/2,text,length+1,NULL,NULL);

The data member there is a pointer within this array. This works, it gives me a string of Multibyte characters. Here is the first character: 0xB0 0xB6. Now, for a unicode build, I should be able to read directly from the array: 0x73ED. According to my charmap utility, this is the correct value for this character. But all I see is "?". Ok, try converting the first multibyte result back to wide:

MultiByteToWideChar(CP_ACP,0,text,length,lpW,length+1);

Exactly the same result: 0x73ED. But I am still not seeing it. Lets try the other, simpler, multi to wide function:

mbstowcs(lpW,text,length);

This time the output is a little different: 0x00B0 0x00E0, and I can see it.
Can anybody explain what is going on here?
AnswerRe: I hate Unicode!! Pin
Michael Dunn26-Aug-06 21:27
sitebuilderMichael Dunn26-Aug-06 21:27 
GeneralRe: I hate Unicode!! [modified] Pin
Waldermort26-Aug-06 22:08
Waldermort26-Aug-06 22:08 
GeneralRe: I hate Unicode!! [modified] Pin
fefe.wyx26-Aug-06 22:24
fefe.wyx26-Aug-06 22:24 
GeneralRe: I hate Unicode!! Pin
Waldermort26-Aug-06 22:48
Waldermort26-Aug-06 22:48 
GeneralRe: I hate Unicode!! Pin
fefe.wyx26-Aug-06 23:33
fefe.wyx26-Aug-06 23:33 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.