G
Guest
Hi
I had the following error: Input string was not in a correct format.
from the following code
birthday1 is an integer
yrtype is from the dropdownbo
montype ,, ,, ,
daytype ,, ,, ,
Please advise how I get it right. I really get annoyed in c# because we don't need to handle this in vb.ne
Please help
Ra
string x = string.Concat(yrtype.SelectedItem.Text.Trim(),montype.SelectedItem.Text.Trim(),daytype.SelectedItem.Text.Trim());
acmd.Parameters.Add(new SqlParameter("@birthday1", SqlDbType.Int))
acmd.Parameters["@birthday1"].Value = Convert.ToInt32(x);
I had the following error: Input string was not in a correct format.
from the following code
birthday1 is an integer
yrtype is from the dropdownbo
montype ,, ,, ,
daytype ,, ,, ,
Please advise how I get it right. I really get annoyed in c# because we don't need to handle this in vb.ne
Please help
Ra
string x = string.Concat(yrtype.SelectedItem.Text.Trim(),montype.SelectedItem.Text.Trim(),daytype.SelectedItem.Text.Trim());
acmd.Parameters.Add(new SqlParameter("@birthday1", SqlDbType.Int))
acmd.Parameters["@birthday1"].Value = Convert.ToInt32(x);