1. Can't find this anywhere - is there a way of checking that a string contains just digits and can therefore be converted to an integer before trying it? I thought there was an IsNumber function but evidently not. Am I just looking for the wrong thing?

TIA,

AndyC
London

2. I beleive what your looking for is the isnumeric() function.

3. The function you looking for is IsNumeric(x) function but if later you try to convert number like 12.3 to integer it will the function
Code:
```Dim int As Integer
Dim str As String
str = "12.3"
if IsNumeric(str) Then int = CInt(str)```
int will be 12

Try it.

[This message has been edited by Kiron (edited 12-02-1999).]

4. IsNumeric! How close!

Thanks all - yes, I was just being thick

AndyC

5. You are looking for the Isnumeric function. It is used for converting between string and numbers. It also returns true if a string can represent a number.
i.e. 1 = 1
-1 = -1

ROSE

6. Andy

My connection is very slow....

ROSE

Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•