Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Two ComboBoxes one datasource
Message
From
17/08/2009 13:39:12
 
 
General information
Forum:
ASP.NET
Category:
Forms
Environment versions
Environment:
C# 3.0
OS:
Windows XP SP2
Application:
Desktop
Miscellaneous
Thread ID:
01418478
Message ID:
01418512
Views:
48
>>Hey Guys, I am having an interesting issue. I have two combos that have the same late bound datasource designed to allow the user to select a subset of the dataset. One Start combo and one stop combo. The code is way simple.
>>
>>
>>            ui_FpStartComboBox.DataSource = Common.FpFolders; //Common.FpFolders is an existing DataTable
>>            ui_FpStartComboBox.DisplayMember = "FpFolders";
>>            ui_FpStartComboBox.ValueMember = "FpFolders";
>>
>>            ui_FpStopComboBox.DataSource = Common.FpFolders;
>>            ui_FpStopComboBox.DisplayMember = "FpFolders";
>>            ui_FpStopComboBox.ValueMember = "FpFolders";
>>
>>The problem is when you select a value in one combo the value of both combos changes to the selected value. This is true when using the mouse or the arrow keys. There are no events registered and I have deleted and recreated the combos with new names. Any combos on the page using the datasource display the same item.
>
>IIRC this is standard behaviour. You'll need different datasources for each instance. Maybe make a list from the dataset and use that for one of them?
>
>>My humble thanks in advance,

I was afraid this was the answer. However, it seems like a real bug. I will load down the app with a copy of data that is already loaded.

Thanks.
~Joe Johnston USA

"If ye love wealth better than liberty, the tranquility of servitude better than the animated contest of freedom, go home from us in peace. We ask not your counsel or arms. Crouch down and lick the hands which feed you. May your chains set lightly upon you, and may posterity forget that ye were our countrymen."
~Samuel Adams

Previous
Next
Reply
Map
View

Click here to load this message in the networking platform