Its often necessary to allow the user to remove a selection from a combox.
In my case, most are bound to lookup tables. I suppose I could, in each
lookup table create an empty record and have in the combobox when its being
filled but there are several reasons why this is not a desirable approach
one is that I would often have to set allownull in the datatable design when
I really need a value. So I need to be able to allow user to simply delete
the currently showing selection from the selected row's combobox and have
the system set the underlying value in the bound table reset to NULL (using
sql server 2005, vs2005 an vb.net). I've been looking for code snippets that
make it possible to do this but haven't found any. All I've found were some
custom controls.
By the way this problem also affects some other controls like Microsoft's
date time picker. In this one if you select date and make a save to the
bound table, I haven't found a way to reforce the underlying table's field
to null. Say user set a starting date of something, saved it, realized thing
had not started yet and wanted to remove the date from the table.
I would really appreciate any info on how to do this.
Bob