jeudi 17 décembre 2015

If else statement between two combobox using c#

I implemented two Combobox in my coding. 1st combobox contain the city name and the 2nd combobox contain the POI of that city. Now I want to implement if else statement between this two combobox. Suppose if I select 1st combobox, Button will enable only for 1st one, then if I select 2nd Combobox then Button will work for 2nd one. I do not know how to do it. My code is like this

public void Download_Click(object sender, EventArgs e)
{
   // if combox1 select
   // all function will work for combobox 1

   //else if combobox2 select
   //combobbox1 disabled and all function will work for combobx2    
}

Aucun commentaire:

Enregistrer un commentaire