![]() | |
![]() |
| | Thread Tools | Display Modes |
#11
| |||
| |||
|
|
Marshall Barton <marshbarton (AT) wowway (DOT) com> wrote: Sometimes, but not always. IsNumeric will return True for anything that can represent a number, even somewhat obscure number styles such as: +1.234E-3 -1.234D+3 $12.34- $(12.34) which makes IsNumeric useless in most situations where you might expect it to work. I think this is an unnecessary worry. No account number is going to have those characters. |
#12
| |||
| |||
|
|
How about: 12345D6 543E21 The original question was to see if it was all digits optionally followed by a letter. Clearly IsNumeric does not detect some failures to meet the requirement. |
#13
| |||
| |||
|
|
sfdavidkaye2 (AT) yahoo (DOT) com (David Kaye) wrote: Slight correction. Note the 0 to 9 addition: select case right$(str$,1) case "A" to "Z", "a" to "z", "0" to "9" if maybeok then isokay=true else isokay=false end if case else isokay=false end select |
#14
| |||
| |||
|
|
sfdavidkaye2 (AT) yahoo (DOT) com (David Kaye) wrote: Slight correction. Note the 0 to 9 addition: select case right$(str$,1) case "A" to "Z", "a" to "z", "0" to "9" if maybeok then isokay=true else isokay=false end if case else isokay=false end select |
![]() |
| Thread Tools | |
| Display Modes | |
| |