MultiByteToWideChar

This content has moved to another location. See MultiByteToWideChar for the latest version.

Tags :


Community Content

Shawn Steele [MSFT]
Don't use MB_PRECOMPOSED and MB_COMPOSITE

First of all, MB_COMPOSITE is a horrible name. It kind of means "normalization form D", which I think of as "decomposed". MB_PRECOMPOSED is sort of "normalization form C".

Instead use NormalizeString() after conversion. NormalizeString() provides more accurate, standard, and consistent data than these flags. It can also be faster.

Also note that MB_PRECOMPOSED has very little effect on most code pages because most of the input data is composed anyway, so the extra processing is often wasted effort.

Tags :

Page view tracker