jamesdean666
asked on
Error message during Databind in C#/Visual Studio 2008
I am trying to databind an integer from a text box and am getting the following error:
System.FormatException was unhandled
Message="Input string was not in a correct format."
Source="mscorlib"
I am successfully populating a text box with a number - say 21139.
This is the line of code I am getting the error on:
mortgee.MortId = int.Parse(this.txtNextMort Id.Text.To String());
Where mortgee is a business object i have created, and MortId is a public member that is an integer.
Any Ideas.. I hope I described this ok.
I try to bind to this value with the below code:
System.FormatException was unhandled
Message="Input string was not in a correct format."
Source="mscorlib"
I am successfully populating a text box with a number - say 21139.
This is the line of code I am getting the error on:
mortgee.MortId = int.Parse(this.txtNextMort
Where mortgee is a business object i have created, and MortId is a public member that is an integer.
Any Ideas.. I hope I described this ok.
I try to bind to this value with the below code:
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER