Example #1
0
        public void SortByMonth(int month)
        {
            TBikeDAL MyDAL = new TBikeDAL();

            if (month == 1)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :January";
            }
            else if (month == 2)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :February";
            }
            else if (month == 3)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :March";
            }
            else if (month == 4)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :April";
            }
            else if (month == 5)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :May";
            }
            else if (month == 6)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :June";
            }
            else if (month == 7)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :July";
            }
            else if (month == 8)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :August";
            }
            else if (month == 9)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :September";
            }
            else if (month == 10)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :October";
            }
            else if (month == 11)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :November";
            }
            else if (month == 12)
            {
                MyDAL.bindListBox(ListBooking, month);
                TBMonth.Text = "Date :December";
            }

            datebymonth = month;
        }