Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

Vb.net Help


  • Please log in to reply
2 replies to this topic

#1 shortymac

shortymac

  • Members
  • 34 posts
  • OFFLINE
  •  
  • Local time:01:04 PM

Posted 25 November 2005 - 02:28 PM

ok, i'm trying to covert a text box info into a string then into decimal format, like this

sSalary = txtSalary.ToString
Salary = Decimal.Parse(sSalary)

i tired
Salary = Decimal.Parse(txtSalary.ToString)

no matter what i do, i keep on getting this error message at runtime "Input string was not in a correct format"

i dont understand why this is happening, i dont get an error message when compling

please help
Despite many reverses, freedom has won many battles. Many died in those battles in the conviction that to die in the struggle against oppression was better than to live without freedom. Such a death is the utmost assertion of their individuality. ~ Erich Fromm

BC AdBot (Login to Remove)

 


#2 Underwhelmed

Underwhelmed

  • Members
  • 67 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Naperville, IL
  • Local time:12:04 PM

Posted 29 November 2005 - 05:09 PM

Try:

Salary = Decimal.Parse(txtSalary.Text)

Tacos. That is all you ever need know.

My Development Blog

#3 shortymac

shortymac
  • Topic Starter

  • Members
  • 34 posts
  • OFFLINE
  •  
  • Local time:01:04 PM

Posted 18 December 2005 - 04:56 PM

i did that and it worked! thanks!
Despite many reverses, freedom has won many battles. Many died in those battles in the conviction that to die in the struggle against oppression was better than to live without freedom. Such a death is the utmost assertion of their individuality. ~ Erich Fromm




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users