Problems with ISnumeric

G

Guest

Hi,
i have a problem with this function,
i have installed in my computer the framework (v1.1.4322) and Isnunmeric set
to false the next operation:
isnumeric ("1")
in another computers that works fine but in my computer i have that results.
Code was "compiled" in another machine and i only install the application in
my machine.
Someone knowns why that runs in another way around ?
 
C

cody

do you mean the visual basic function IsNumeric? I don't believe there is a
bug in that function, there must be something wrong with your code, maybe
you could post it here?
 
G

Guest

Hi cody,
i don't known what is happening(maybe some problems with another
program....) but the code is that:

If Not (IsNumeric(strintDepotNumber)) Then
Throw New Exception(String.Format("intDepotNumber parameter
must be numeric: '{0}' [{1} chars]", strintDepotNumber,
strintDepotNumber.Length))
Else
intDepotNumber = CInt(strintDepotNumber)
End If

and the msgbox say that(input parameter :789):

intDepotNumber parameter must be numeric: '789' [3 chars]

thanks
 
C

Cor Ligthert [MVP]

FHR,

Why do you not to test it change your code first in

\\\
If Not IsNumeric("789") Then
Throw New Exception(String.Format("intDepotNumber parameter
must be numeric: '{0}' [{1} chars]", strintDepotNumber,
strintDepotNumber.Length))
Else
intDepotNumber = CInt("789")
End If
///
I hope this helps,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top