CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Search found 3 matches
CCS Forum Index
Author Message
  Topic: Convert '1' to 49, 'B' to 66 ...
METsai

Replies: 7
Views: 8727

PostForum: General CCS C Discussion   Posted: Fri Dec 15, 2006 9:40 pm   Subject: Converting
Thank you for your help.

Your code helps me a lot.

But there is a strange situation.

When NumberToConvert is '0' ~ 'c', your code works fine.

When NumberToConvert is 'd', Result has '1' ...
  Topic: Convert '1' to 49, 'B' to 66 ...
METsai

Replies: 7
Views: 8727

PostForum: General CCS C Discussion   Posted: Tue Dec 12, 2006 1:53 am   Subject: Convert '1' to 49, 'B' to 66 ...
Thank you for your help.

But I do not printf it.

I know printf can print ascii code,

char mystring;
mystring = 'D';
printf("mystring = %d", mystring);

>> mystring =68
...
  Topic: Convert '1' to 49, 'B' to 66 ...
METsai

Replies: 7
Views: 8727

PostForum: General CCS C Discussion   Posted: Tue Dec 12, 2006 12:25 am   Subject: Convert '1' to 49, 'B' to 66 ...
Hi

Does anyone know how to convert ascii to number, ex: '1' to 49,

'D' to 68, 'i' to 105, 'u' to 117 ... Does CCS provide this function?

Or someone knows how to do that?

Thank you for ...
 
Page 1 of 1
All times are GMT - 6 Hours
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group