Quantcast
Channel: Windows Forms Data Controls and Databinding forum
Viewing all articles
Browse latest Browse all 2535

Databound ComboboxCell in a DatagridView

$
0
0

Hello-

As part of a project our team was given there is a new request to have the following logic instituted.

When a user is saving forms, "hold over" the values from the comboboxes in one of the datagridviews.

This datagridview-combobox is databound onload and allows the user to select an item and then it creates another combobox for selection of another item (same data). (They do not want to have the user multi select in the same combobox)

The above allows for "limitless" comboboxes.

For example , in DGView1 , we have comboBox1 with a selected value of Apple , once selected the 2nd combobox appears and then the user selected Onion, and so on and so on (i.e. user COULD select the same values in each box, but that is neither here nor there)

So what they would like is when the user elects to Add a new record (during the same session) is recall the LAST values and have the comboboxes preselected with these values.

I have tried various pieces of code found over the net and although I am able to "set" the display value, any interaction with the combobox removes this also I have not been able to set more than 1 value regardless of how many values I have selected previously.

Any code you could point me to that we could try and see about overcoming this challenge ?

Thank you

Ken


Viewing all articles
Browse latest Browse all 2535

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>