i have 3 tables Category, CityMaster and Data
Next, i Have 2 comboboxes For City and Category.
In my Category Table i have Two columns Category and Category ID which is unique for each Category.
In my CityMaster table i have 2 columns CityName and CityID wherein each CityName has a corresponding CITYID eg
Mumbai 1 etc...
In my Data datable i have 4 columns
Name , Address CITYID and CATEGORY ID .
IN my city Combobox all the Name of the cities should be listed.
When the user selects a particular CITY its corresponding category should be listed IN THE ANOTHER COMBOBOX named Category.
Till now i have done :
protected void Page_Load(object sender, EventArgs e)
{
SqlDataReader dr = null;
SqlCommand command = new SqlCommand("Select City_Name from City_Master",conn);
conn.Open();
dr = command.ExecuteReader(CommandBehavior.CloseConnection);
ddlcity.DataSource = dr;
ddlcity.DataTextField = "City_Name";
ddlcity.DataValueField = "City_Name";
ddlcity.DataBind();
}
}
PLZ TELL ME HOW TO PROCEED FURTHER ??
CYA
ROHAN