1. Since Windows NT, all versions of Windows are built entirely in Unicode, and when invoking a Windows function, if an ANSI string is passed to it, the function first converts the string to Unicode and then passes the result to the operating system. If you want the function to return an ANSI string, the operating system will first convert the Unicode string to an ANSI string and return the result to our application. Therefore, the system generates time and memory overhead.
2. All COM interface methods that require strings as arguments accept only Unicode strings.
3. By default, when you create a new C + + project in VS, _unicode is already defined (as if UNICODE was already defined). For identifiers that are not part of the C + + standard library, the C Runtime library always appends an underscore prefix to them. However, the Windows team did not, so in the application, you should make sure that either UNICODE and _UNICODE are defined at the same time, or none of them are defined.
Windows Internals Notes--character and string processing