Sebastian Irazabal

Convert Integer to String and vice versa

Discussion created by Sebastian Irazabal on Nov 6, 2006
Latest reply on Nov 7, 2006 by Steve Melnikoff
Hi, folks!

Well, I'm working with HCS12, with CodeWarrior compiler and I'm progamming it in C language.
Now I need to convert a string to integer, and then an integer to string. I've been told that I should use the atoi() and itoa() functions.... And in order to do that I must include "stdio.h" and "stdlib.h".
The problem is that it says that itoa doesn't exist. I guess it means that it's not in "stdlib.h"...So I downloaded another version of "stdlib.h" that has the itoa() function..... You won't beleive that, but this "stdlib.h" I've downloaded does not have the other function atoi().... WHAT CAN I DO??????

PS: I try to copy what I thought was the declaration of the missing function from the other header but it still doesn't work.

THANKS

Outcomes