On an asp.net2 page I have a DropDownList in the item template of a databound template of a DetailsView control. Everything works fine if the databound value is a member of the items-list of the DropDownList. But, when a value not on the list, typically a null value is encountered an error is thrown. How can I have the DropDownList accept null values ? How can I have the DropDownList check for and handle values not on the item list ? Thanks in advance for your help, Jim
Jim McGivney wrote: > On an asp.net2 page I have a DropDownList in the item template of a > databound template of a DetailsView control. > Everything works fine if the databound value is a member of the > items-list of the DropDownList. > But, when a value not on the list, typically a null value is > encountered an error is thrown. > How can I have the DropDownList accept null values ? > How can I have the DropDownList check for and handle values not on > the item list ? > Thanks in advance for your help, > Jim See http://weblogs.asp.net/hpreishuber/archive/2006/02/02/437158.aspx for a solution to this. -- Riki