| | |
assigning a TCHAR char array to std::string
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
UNICODE is the default setting for that compiler so if you didn't turn it off then the compiler is mapping TCHAR into wchar_t. go to Project --> Properties (bottom menu item) --> Configuration Properties --> General then change Character Set option to Not Set. If you really do want UNICODE then you have to use one of the conversion functions to convert wchar_t* to char*
Last edited by Ancient Dragon; Sep 20th, 2007 at 9:41 am.
Don't PM me with questions -- you might get a nasty PM in response. If you have a question then post it in one of the forums.
•
•
Join Date: Aug 2007
Posts: 18
Reputation:
Solved Threads: 0
•
•
•
•
UNICODE is the default setting for that compiler so if you didn't turn it off then the compiler is mapping TCHAR into wchar_t. go to Project --> Properties (bottom menu item) --> Configuration Properties --> General then change Character Set option to Not Set. If you really do want UNICODE then you have to use one of the conversion functions to convert wchar_t* to char*
i want to do in UNICODE only so can u suggest me those conversion functions??
![]() |
Similar Threads
- One line of code copy char array using pointers (C++)
- Scan File for Comments (C++)
- TCHAR to std::string (C)
- Comparing two letters in one string with another char string? (C)
- first cannot conver std::string to const char, now runtime error! (C++)
- How to find End of file (C++)
- converting std::string to const chars? (C++)
- How to assign my own numeric values to a char array? (C++)
- two-dimensional char array (Java)
Other Threads in the C++ Forum
- Previous Thread: help with list view
- Next Thread: Terminal size
| Thread Tools | Search this Thread |
api array arrays based beginner binary bitmap c++ c/c++ calculator char class classes code compile compiler console conversion count delete deploy desktop directshow dll download dynamic dynamiccharacterarray encryption error file forms fstream function functions game getline givemetehcodez google graph gui homeworkhelp homeworkhelper iamthwee ifstream input int integer java lib linkedlist linker linux list loop looping loops map math matrix memory news node output parameter pointer problem program programming project proxy python read recursion recursive reference return rpg string strings struct temperature template templates test text text-file tree unix url variable vector video visual visualstudio win32 windows winsock word wordfrequency wxwidgets






