Link to home
Start Free TrialLog in
Avatar of ammotroop
ammotroop

asked on

Convert.ToUInt32

All,

I am trying to use this method that requires the data being sent in to be converted to UInt32.  However, every time I use Convert.ToUIn32() I get an error saying the string is not in the correct format.  Can anyone provide any type of guidance on this command.  I have only used it once for a very minor project.  Thanks.

Jason
Avatar of Swapnil
Swapnil
Flag of India image

Hi ammotroop,

Have you debug it, means have u checked what value string contains which you are going to convert to UInt32. If it contains any alpha characters or it contains the value which is out of range of UInt32?

Regards,
NetSwap
Avatar of ammotroop
ammotroop

ASKER

Well, lets say that I am trying to convert "3".  It gives me an error.  If I just use 3 it gives me an error.  For some reason each time I use it just keeps giving me the same error.

????

I am sure it is something easy but my brain is so fried right now that I can not even think.

Jason
ASKER CERTIFIED SOLUTION
Avatar of ZeonFlash
ZeonFlash

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I running VB.Net 2005 Express Edition.

I have found out that UInt32 is not the correct parameter even though that is what it says on MSDN.  The correct info should have been in string format.  Got it working.  But thanks for the help.

Jason