argument of type const char* is incompatible with parameter of type “LPCWSTR”

To compile your code in Visual C++ you need to use Multi-Byte char WinAPI functions instead of Wide char ones.

Set Project -> Properties -> General -> Character Set option to Use Multi-Byte Character Set

I found it here https://stackoverflow.com/a/33001454/5646315

Leave a Comment