the code is below, getting the value of txtOtherNumber.Value works fine but txtPreferHome.Value and txtPrefer.Value are either True or False but I am not getting the value into my variables. So if something is false I want to populate a textbox on the form with a different value that has come back from the database?
code
code
if (txtOtherNumber.Value.StartsWith("type"))
{
txtOtherNumber.Value = string.Empty;
}
string preferHome = txtPreferHome.Value;
string preferOther = txtPreferOther.Value;
string homeNumber = txtHomeNumber.Value;
string otherNumber = txtOtherNumber.Value;
//Tom wants the prefer contact number at the top
if (txtPreferHome.Value == "False"))
{
txtHomeNumber.Value = otherNumber;
txtOtherNumber.Value = homeNumber;
txtPrefer.Value = "Some Value";
}