I have two combobox .. and i have some items in both combobox
now i need to check the item in both combobox if same item
is Present in both combobox i need to display that item in
message box
Answer Posted / kirupa
for (int i = 0; i <= comboBox1.Items.Count-1; i++)
{
for (int j = 0; j <= comboBox2.Items.Count-1; j++)
{
if (comboBox1.Items[i].ToString() == comboBox2.Items
[j].ToString())
MessageBox.Show(comboBox1.Items[i].ToString());
}
}
| Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
What are window applications?
What is the difference between a document and a form?
Explain the need of z-order method?
What is the use of runworkasync() methods?
What is a database form?
How to use the FindControl() function to preselect an item in my dropdownlist?
Name the property which of menu cannot be set at run time?
What is the difference between pixels, points, and em’s when fonts are displayed?
What is form technology?
Explain the difference between listbox and combo box?
What are controls in windows forms?
Explain the difference between listindex and tab index?
Explain how barcode create in the report?
How do I change the console application in windows?
how print PGL by XML