Hey All. I want to collect a string variable and an integer variable from 2 input boxes. From there I want to confirm they are string/int with try-catch, lastly, I want to upload that to a data table giving the user the option to submit again. Any ideas?
You are not clear on the requirement…
First, you said you wanna take two inputs from the user and then wants to upload the data table.
Did you miss anything in between?
For checking the integer or not you can use below method.
Int32.TryParse it will give true or false…If it’s int then true and one out parameter will hold the value.
Example : Int32.TryParse(val1, out varInt)