On Wed, 28 Jan 2004, Liguo Song wrote: > Deshpande Bansidhar(IFIN DC AI) wrote: > > >Hi all > > > >I have following code. > >I want to add error handler for atoi() function. > > > >E.g. > > > >char *ch; > >int num; > > > >/*Read ch here*/ > > > >Num = atoi(ch); ^ n and atoi() returns error when it fails, take the time to trap it. HTH -ishwar