G 
		
								
				
				
			
		Guest
Need a little help here.  I saw some related posts, so here goes... I have some textboxes which are designed for the user to enter a integer value.  In "old school C" we just used the atoi function and there you have it.  So I enquired and found the Convert class with it's promising ToInt32 method, great...  but it doesn't work.  The thing keeps throwing Format Exceptions all over the place.  What is the "C#" way to do this???  code
int wmin, wsec, x
int hrs, min, sec, miles
miles = Convert.ToInt32(txtMiles.text)
hrs = Convert.ToInt32(txtHours.text)
min = Convert.ToInt32(txtMinutes.text)
sec = Convert.ToInt32(txtSeconds.text)
. .
I even tried forcing the values to string by using .... miles = Convert.ToInt32(txtMiles.text.ToString())
still not working...
Help!
				
			int wmin, wsec, x
int hrs, min, sec, miles
miles = Convert.ToInt32(txtMiles.text)
hrs = Convert.ToInt32(txtHours.text)
min = Convert.ToInt32(txtMinutes.text)
sec = Convert.ToInt32(txtSeconds.text)
. .
I even tried forcing the values to string by using .... miles = Convert.ToInt32(txtMiles.text.ToString())
still not working...
Help!
