CString convert error in Embedded Visual C++
-
i want to convert the interger to a binary string in EVC.so i use the '_itot'.
UINT16 high16data = dwReadValue; CString high16string = _itot(high16data, high16string, 2);
the error is:error C2664:'_itow':cannot convert parameter 2 from 'const unsigned short *' how can i convert the parameter?(i do want to use the CString type not the char[] as showed in MSDN). so how to do it? thanks for helping.i 've tried ,then i have no regret
-
i want to convert the interger to a binary string in EVC.so i use the '_itot'.
UINT16 high16data = dwReadValue; CString high16string = _itot(high16data, high16string, 2);
the error is:error C2664:'_itow':cannot convert parameter 2 from 'const unsigned short *' how can i convert the parameter?(i do want to use the CString type not the char[] as showed in MSDN). so how to do it? thanks for helping.i 've tried ,then i have no regret
-
_itot does not accept a CString as parameter. you have to pass a TCHAR* as the second parameter. Why don't you use CString::Format?
-
CString::Format maybe a good choice,i'll try it tomorrow:)
i 've tried ,then i have no regret
CHYGO wrote:
i'll try it tomorrow :)
It will be a good day :)
virtual void BeHappy() = 0;
-
CHYGO wrote:
i'll try it tomorrow :)
It will be a good day :)
virtual void BeHappy() = 0;