private void BindAirportDropdowns()
    {
        ArrayList airportList = new ArrayList();

        airportList.Add(new Airport(0, string.Empty, string.Empty, "-- " + GetMessage("selectAirport") + " --"));
        airportList.AddRange(airportDao.GetAllAirports());

        leavingFromAirportCode.DataSource     = airportList;
        leavingFromAirportCode.DataTextField  = "Description";
        leavingFromAirportCode.DataValueField = "Code";
        leavingFromAirportCode.DataBind();

        goingToAirportCode.DataSource     = airportList;
        goingToAirportCode.DataTextField  = "Description";
        goingToAirportCode.DataValueField = "Code";
        goingToAirportCode.DataBind();
    }
示例#2
0
        private void BindAirportDropdowns()
        {
            ArrayList airportList = new ArrayList();

            airportList.Add(GetNothingAirport());
            airportList.AddRange(airportDao.GetAllAirports());

            leavingFromAirportCode.DataSource     = airportList;
            leavingFromAirportCode.DataTextField  = "Description";
            leavingFromAirportCode.DataValueField = "Code";
            leavingFromAirportCode.DataBind();

            goingToAirportCode.DataSource     = airportList;
            goingToAirportCode.DataTextField  = "Description";
            goingToAirportCode.DataValueField = "Code";
            goingToAirportCode.DataBind();
        }
 public AirportCollection GetAirportList()
 {
     return(airportDao.GetAllAirports());
 }