Solved

Combobox

Posted on 2009-04-14
4
231 Views
Last Modified: 2013-11-26
I have a simple database with two columns, ItemNo & Description. On my form I have 8 comboboxes being used to list the ItemNo(s) from the database by bindingsource. When I select an item number in the first combobox, the other seven cb's fill with the same item number. If I select another item number in a different combobox all the others change with it. I need to have the cb's act independantly.

What do I need to do to correct the problem?
0
Comment
Question by:Tim313
  • 2
4 Comments
 
LVL 18

Accepted Solution

by:
UnifiedIS earned 125 total points
ID: 24141434
Sounds like all 8 combos are bound to the same source.
0
 
LVL 1

Assisted Solution

by:Abhishekoops
Abhishekoops earned 125 total points
ID: 24154591
Ya it seems here all the combo boxes are getting binded to the same single field you are trying to modify.
If you cant really figure out just delete the control then try to configure it with one combo box then move on with the next one and bind it with the required source so that you can avoid the things where you are really making a mistake.
Even if not the do paste your code related to your combo box so that i can have a look at it.
0
 

Author Comment

by:Tim313
ID: 24156109
Yeh, I thought binding all 8 boxes to a single field may be the problem. I expanded the database from one "ItemNo" field to 8 fields (all identical with different field names), then bound each combobox to its own field but still got the same results (change one, change all). I had a similar problem setting up two comboboxes on a different form and actually had to create two separate tableadapters to work around the problem. I don't have much code, I'm simply dropping the boxes onto the form from "Data Sources" in designer mode. I'm hoping I don't have to create 8 tableadapters to work around this problem.

I'll try building the form one box at a time to see if I can find the error. I'll repost the results shortly...

Thanks!
0
 

Author Closing Comment

by:Tim313
ID: 31570071
Purely by accident, I found the problem. Since I was using a single data source, I needed to set up multiple bindings (one for each cb). Thanks for steering me in the right direction.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now