Python Nutter wrote:
Type casting seems to be the wrong way to go about this.teststring = '15719' teststring.isdigit() returns True
Actually its instantiating not type casting and it works by using the type's actual description of the data it accepts. This looks pretty good approach instead of trying to copy (incomplete as it has been shown not only digits and . constitute a float) already implemented code. Of course if you want to limit the range of accepted data even more, then isdigit and friends can be used - maybe you could time both approaches with a set of data. Regards Tino
smime.p7s
Description: S/MIME Cryptographic Signature
-- http://mail.python.org/mailman/listinfo/python-list