Show manufacturers in dropdownlist

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
15 years ago
I want to show manufacturers in dropdownlist, instead of how it is layed out now. How can I do it?
15 years ago
Hello

Add DropDownList to ManufacturerNavigation.ascx user control. And modify ManufacturerNavigation.ascx.cs:

ManufacturerCollection manufacturers = ManufacturerManager.GetAllManufacturers();
this.ddlManufacturer.Items.Clear();
foreach (ManufacturerTemplate manufacturer in manufacturers)
{
      ListItem item2 = new ListItem(manufacturer.Name, manufacturer.ManufacturerID.ToString());
      this.ddlManufacturer.Items.Add(item2);
}
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.