R
Rick Shaw
Hi. I've struggling with the combobox databinding in C#. What I was trying
to do was:
- Hard code the items in the combobox's Items (collection) property. (ie.
'Mon', 'Tue', 'Wed', 'Thu', 'Fri')
- Then databind the combobox to a table in the dataset.
Since the table (in the dataset) contains just a tiny subset (1 to 5
records) of what is in the database, it might contain, for example,
the values 'Mon' and 'Thu' only.
Right now, when I databind the control to the dataset, I think, it clears
the hard coded items in the control and replace it with what in the table.
Can someone help.
Thanks,
Rick..
to do was:
- Hard code the items in the combobox's Items (collection) property. (ie.
'Mon', 'Tue', 'Wed', 'Thu', 'Fri')
- Then databind the combobox to a table in the dataset.
Since the table (in the dataset) contains just a tiny subset (1 to 5
records) of what is in the database, it might contain, for example,
the values 'Mon' and 'Thu' only.
Right now, when I databind the control to the dataset, I think, it clears
the hard coded items in the control and replace it with what in the table.
Can someone help.
Thanks,
Rick..