Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to Update Not Bounded Fields
Message
 
To
13/01/2003 11:25:39
General information
Forum:
ASP.NET
Category:
ADO.NET
Miscellaneous
Thread ID:
00739818
Message ID:
00741022
Views:
32
Thanks Bonnie, I got what you mean.


>Ahmad,
>
>Well, it really depends on what you're using your ComboBox for. If you only have one ComboBox on your form and you're only using it for navigation of the DataSet on the Form, then it's ok for it to have the same DataSet as it's DataSource, because picking an item from the ComboBox *will* cause the BindingContext Position to change. In this particular case (using the combo for navigation) this would be the behavior that you want to accomplish.
>
>But, if you have more than one Combo on your form and they use the same DataSet as their DataSource, you will never be able to set the Combo's independently ... they'll always contain the exact same SelectedItem.
>
>And if you're using a Combo strictly has a pick-list kind of thing, you run into the same problem with it moving the BindingContext Position of your DataSet when that is not your intent.
>
>To see what I mean, test it out for yourself with a simple form. Drop on two Combos, a Text Box and two buttons. Create a DataSet and stick 3 or 4 records in it. DataBind your TextBox to the Table, and set the DataSource of your combos to the Table. Have the two buttons be a Back and Next button and change the BindingContext Position in their Click events. Then, watch what happens ....
>
>~~Bonnie
>
>
>
>>Hi Bonnie,
>>
>>What did you mean by my ComboBox DataSet should *not* be the same my main DataSet?
>>
>>
>>
<><><><><><><><><><><><><><><><><><><><>
<><> REMEMBER,,,,KNOWLEDGE IS POWER <><>
<><><><><><><><><><><><><><><><><><><><>
Previous
Reply
Map
View

Click here to load this message in the networking platform