private void LoadCities() { City c = new City(); if (c.LoadByCountryID(CountryID)) { do { HtmlTableRow row = new HtmlTableRow(); row.Cells.Add(AddCityCellInnerHTML(c.GetColumn("Name" + Utils.LangPrefix).ToString(), c.GetColumn("CountryName").ToString(), c.GetColumn("Name_en").ToString())); tblCities.Rows.Add(row); } while (c.MoveNext()); } }
public void LoadCityDDL(int countryID) { ddlList.Items.Clear(); City c = new City(); c.Where.CountryID.Value = countryID; c.Query.AddOrderBy(City.ColumnNames.Name, WhereParameter.Dir.ASC); if (c.Query.Load()) { do { RadComboBoxItem item = new RadComboBoxItem(c.s_Name, c.CityID.ToString()); this.ddlList.Items.Add(item); } while (c.MoveNext()); } }
protected override void InitDDL() { City c = new City(); if (CountryID > 0) { c.Where.CountryID.Value = CountryID; } c.Query.AddOrderBy(City.ColumnNames.Name_uk, WhereParameter.Dir.ASC); if (c.Query.Load()) { do { RadComboBoxItem item = new RadComboBoxItem(c.s_Name_uk, c.CityID.ToString()); this.ddlList.Items.Add(item); } while (c.MoveNext()); } }