Compiler Error C2002
invalid wide-character constant
The multibyte-character constant is not valid.
To fix by checking the following possible causes
The wide-character constant contains more bytes than expected.
The standard header STDDEF.h is not included.
Wide characters cannot be concatenated with ordinary string literals.
A wide-character constant must be preceded by the character 'L':
L'mbconst'
For Microsoft C++, the text arguments of a preprocessor directive must be ASCII. For example, the directive,
#pragma message(L"string")
, is not valid.
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for