simon@alberta.UUCP (Simon Tortike) (09/13/88)
In article <1585@pembina.UUCP>, simon@alberta.UUCP (Simon Tortike) writes: > I am writing an application that requires me to change a string into a > float or double number. The input is already partly filtered (a filterproc > in a modal dialog) but I still need to check the exponentiation, etc. > K&R (2nd. ed) document `double strtod(const char *s, char **endp)' as part > of the header file <stdlib.h>, which returns information in *endp whether > the entire string was converted. In my case, I wish to reject the number (sheepishly) well I suppose I should have tried harder before mailing this, but I have a perfectly good form of strtod now. If anyone wants a copy I'll mail it to them. By the way, has anyone else noticed that the Stubs.c file for use when making MPW tools in C removes the floating point formatting? I got garbage for two hours before I realised my programming ability wasn't all that bad. > ------------------- > Simon Tortike, Department of Mining, Metallurgical and Petroleum Engineering, > The University of Alberta, Edmonton, AB, CANADA T6G 2G6. > simon@alberta.uucp | AGT: 403/432-3338 | stortike@ualtavm.bitnet (That's me.)