DECLARE FUNCTION isnumeric$ LET true$ = "True" LET false$ = "False" LET s$ = "-152.34" PRINT s$, " => "; isnumeric$(s$) LET s$ = "1234.056789" PRINT s$, " => "; isnumeric$(s$) LET s$ = "1234.56" PRINT s$, " => "; isnumeric$(s$) LET s$ = "021101" PRINT s$, " => "; isnumeric$(s$) LET s$ = "Dog" PRINT s$, " => "; isnumeric$(s$) LET s$ = "Bad125" PRINT s$, " => "; isnumeric$(s$) LET s$ = "-0177" PRINT s$, " => "; isnumeric$(s$) LET s$ = "+123abcd.ef" PRINT s$, " => "; isnumeric$(s$) LET s$ = "54321" PRINT s$, " => "; isnumeric$(s$) LET s$ = "123xyz" PRINT s$, " => "; isnumeric$(s$) LET s$ = "xyz" PRINT s$, " => "; isnumeric$(s$) FUNCTION isnumeric$(s$) LET optchar$ = "" IF len(s$) = 0 then LET isnumeric$ = false$ EXIT FUNCTION END IF IF pos(s$,"+") > 1 then LET isnumeric$ = false$ EXIT FUNCTION END IF IF pos(s$,"-") > 1 then LET isnumeric$ = false$ EXIT FUNCTION END IF LET ndex = 0 FOR i = 1 to len(s$) SELECT CASE ord((s$)[i:i+1-1][1:1]) CASE 43 !+ CASE 45 !- CASE 46 !. IF ndex = 1 then LET isnumeric$ = false$ EXIT FUNCTION END IF LET ndex = 1 CASE 48 to 57 !0 a 9 CASE else IF pos(optchar$,((s$)[i:i+1-1])) = 0 then LET isnumeric$ = false$ EXIT FUNCTION END IF END SELECT NEXT i LET isnumeric$ = true$ END FUNCTION END