Solved

Implementing Combo box filter on window form : C# .NET 1.1

Posted on 2006-11-14
3
1,828 Views
Last Modified: 2012-06-27
Hi,
I am currently using .net framework1.1  and window forms.
In one form i got two combo boxes in which values are coming from two different tables.
I want to make it such that if a user selects item from the first combo box
it filters the values and shows only relavent ones in the second combo box.
Please give some idea or option to do it.

thanks
0
Comment
Question by:AbhilashN
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 5

Accepted Solution

by:
rameedev earned 500 total points
ID: 17944945
There are couple of ways of doing it....

1) Load first combobox from first table. On selecting a vlues from the 1st combo get the value and use it to construct a sql statement based on this value and use it to load the 2nd combo,

// other way

2) Load 2 datasets from both the sql tables and use the first one to bind it to the 1st combo. On selecting a value from the first combo use the selected value to make a query on the 2nd dataset you will get an array of datarows...use it to constrcut datatable and bind it to the 2nd combo.

the 2nd dataset loaded initially must also have the column which is there in the 1st combo
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

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

This article introduced a TextBox that supports transparent background.   Introduction TextBox is the most widely used control component in GUI design. Most GUI controls do not support transparent background and more or less do not have the…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

756 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