I have Patient details form. From that I am storing the data to DB using Stored Procedure.
In table, all fields are allowed null except Primary key.
When I store data, then I will stored using .Text property.
For non-mandatory field, if text box value is "" then it will stored, but in case DropDownList if I pass empty string ("") to DB then it will show me error as
"Input string was not in correct format"
I have used DropDownList's SelectedItem.Text and SelectedValue . But in both case it show me the same error.
Is there any case to pass default value of DropDown value as NULL?
Or any other idea?
Note : I am using LINQ. (.NET FW 3.5) and SQL Server 2008.
"Knowledge Shared Is Knowledge Gained"Friday, March 05, 2010 9:29 AM