Microsoft
Software
Hardware
Network
Question : Problem: How do I convert an octal CString to an integer using eVC on WinCE?
I need to convert a 3-digit octal MFC CString (with leading zeroes) to a numeric integer. For example "110" would be 72, and "077" would be 63. It needs to compile using Embedded Visual C++ 4 and run on WinCE 4, and preferably use an efficient API or standard library function.
Answer : Problem: How do I convert an octal CString to an integer using eVC on WinCE?
That means you are compiling UNICODE. Use 'wcstol()' instead, i.e.
1:
int value = wcstol( (LPCTSTR)text, NULL, 8 );
Open in New Window
Select All
Random Solutions
Problem: Monitor Sleeps
Problem: Getting into settings of Bios
Problem: Samsung LCD's with built in PC for Digital Signage
Problem: Need to Buy New Dell Server
Problem: General iPhone activation question
Problem: Backup Problem with HP DAT72 USB drive using NTBackup
Problem: Itunes won't install
Problem: Norton 2003 Ghost Clone Failure
Problem: RS232 12 volt output needed to fire cash drawer
Problem: BackupExec not seeing autoloader (Exabyte) but used to