Possible Duplicate:
char array to LPCTSTR conversion in c
how can convert LPCSTR string into LPCTSTR string?
There is lot of material available already but I am new to C++ so I couldn't understand them properly. Please help.
Possible Duplicate:
char array to LPCTSTR conversion in c
how can convert LPCSTR string into LPCTSTR string?
There is lot of material available already but I am new to C++ so I couldn't understand them properly. Please help.
google gave me this link, with a lot of information.
The type-name LPCTSTR can be classified as:
LP - Pointer
C - Constant
T = TCHAR
STR = String
Depending on the project settings, LPCTSTR would be mapped to either LPCSTR (ANSI) or LPCWSTR (Unicode).
The type-name LPCSTR can be classified as:
LP - Pointer
C - Constant
STR = String
A STR is the same as a char*
The type-name LPCWSTR can be classified as:
LP - Pointer
C - Constant
WSTR - Wide character String
here a WSTR is a wchar_t* or a wide char (2 byte char)
And last but not least this article on how to do the conversion. As you can see there is a bit more to it that a simple type conversion.