Solved

Combobox

Posted on 2009-04-14
4
235 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

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Recently while returning home from work my wife (another .NET developer) was murmuring something. On further poking she said that she has been assigned a task where she has to serialize and deserialize objects and she is afraid of serialization. Wha…
Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
Email security requires an ever evolving service that stays up to date with counter-evolving threats. The Email Laundry perform Research and Development to ensure their email security service evolves faster than cyber criminals. We apply our Threat…

856 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