Click here to Skip to main content
15,885,546 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Button does not change the position when I resize my dialog Pin
pandit8420-May-09 5:03
pandit8420-May-09 5:03 
AnswerRe: Button does not change the position when I resize my dialog Pin
David Crow20-May-09 5:42
David Crow20-May-09 5:42 
QuestionSet Dialog Size Pin
MsmVc20-May-09 2:55
MsmVc20-May-09 2:55 
AnswerRe: Set Dialog Size Pin
Cedric Moonen20-May-09 3:03
Cedric Moonen20-May-09 3:03 
AnswerRe: Set Dialog Size Pin
Nuri Ismail20-May-09 3:08
Nuri Ismail20-May-09 3:08 
QuestionRe: Set Dialog Size Pin
David Crow20-May-09 5:45
David Crow20-May-09 5:45 
QuestionCode from visual studio 7.1 don't want to work on visual studio 2008 Pin
hrddd20-May-09 2:51
hrddd20-May-09 2:51 
AnswerRe: Code from visual studio 7.1 don't want to work on visual studio 2008 Pin
Cedric Moonen20-May-09 3:02
Cedric Moonen20-May-09 3:02 
The difference between VC7 and VC8 (related to your error I mean) is that in VC2008, UNICODE is defined by default. If you want to better understand what that means, I suggest this article[^].

In your code snippet, you are not being consistent neither: sometimes you are using a char arrays, sometimes a TCHAR array. So, either you do not care at all about unicode and only use char array, or you care about UNICODE and use TCHAR arrays everywhere. But using both is ugly.

On the other hand, std::string do not support wide characters, so that's why you have the compilation error. For that part, if you want to support unicode builds, I suggest you define your own type:
#if defined _UNICODE || defined UNICODE
	typedef std::wstring TMyString;
#else
	typedef std::string TMyString;
#endif


This way, you'll be independant of the unicode settings.

Cédric Moonen
Software developer

Charting control [v2.0]
OpenGL game tutorial in C++

QuestionADO in a DLL Pin
staticv20-May-09 2:51
staticv20-May-09 2:51 
AnswerRe: ADO in a DLL Pin
led mike20-May-09 4:29
led mike20-May-09 4:29 
GeneralRe: ADO in a DLL Pin
staticv20-May-09 5:25
staticv20-May-09 5:25 
GeneralRe: ADO in a DLL Pin
led mike20-May-09 6:00
led mike20-May-09 6:00 
GeneralRe: ADO in a DLL Pin
staticv20-May-09 6:12
staticv20-May-09 6:12 
QuestionEnableWindow(False) is not working for disabling a group box . Pin
munisha120-May-09 2:39
munisha120-May-09 2:39 
AnswerRe: EnableWindow(False) is not working for disabling a group box . Pin
_AnsHUMAN_ 20-May-09 2:47
_AnsHUMAN_ 20-May-09 2:47 
QuestionPlease Wait Message Pin
Davitor20-May-09 1:51
Davitor20-May-09 1:51 
AnswerRe: Please Wait Message Pin
CPallini20-May-09 1:58
mveCPallini20-May-09 1:58 
AnswerRe: Please Wait Message Pin
_AnsHUMAN_ 20-May-09 2:20
_AnsHUMAN_ 20-May-09 2:20 
AnswerRe: Please Wait Message Pin
Rajesh R Subramanian20-May-09 2:43
professionalRajesh R Subramanian20-May-09 2:43 
GeneralRe: Please Wait Message Pin
Davitor20-May-09 2:51
Davitor20-May-09 2:51 
QuestionRe: Please Wait Message Pin
Rajesh R Subramanian20-May-09 3:12
professionalRajesh R Subramanian20-May-09 3:12 
QuestionHow to color the background of a row in list control Pin
12Code20-May-09 0:43
12Code20-May-09 0:43 
AnswerRe: How to color the background of a row in list control Pin
Nuri Ismail20-May-09 1:39
Nuri Ismail20-May-09 1:39 
GeneralRe: How to color the background of a row in list control Pin
12Code20-May-09 2:59
12Code20-May-09 2:59 
AnswerRe: How to color the background of a row in list control Pin
Hamid_RT20-May-09 1:54
Hamid_RT20-May-09 1:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.