Question: Type conversion

Discuss PocketC for Palm OS (including Desktop Edition)

Postby Glasswalker on Sat May 19, 2001 3:07 pm

I am having some trouble... I need to be able to convert from the string that represents a number to a number... is this possible in pocketC? for example: I want to be able to enter "45" and then convert it to the number 45 for math and such...
Posts: 47
Joined: Wed Mar 21, 2001 12:18 am
Location: Canada

Postby Tom Miller on Sat May 19, 2001 3:31 pm

Yep, that's easy -- look for a section on type casting in the docs:

num = (int)numstring;

Tom Miller
Posts: 80
Joined: Thu Mar 15, 2001 2:27 pm

Return to PocketC for Palm OS

Who is online

Users browsing this forum: No registered users and 7 guests