protected void rctxtStartingCycle_SelectedIndexChanged(object sender, RadComboBoxSelectedIndexChangedEventArgs e)
    {
        string whereStr;

        vUTPCycle endingCycle;//终止区域

        if (rctxtCompany.SelectedValue != "N/A")
        {
            whereStr     = "  and it.CompanyID='" + rctxtCompany.SelectedValue + "'";
            this.OrderBy = " it.Cycle asc ";

            BLL_vUTPCustomer = new vUTPCustomerBLL();
            endingCycle      = BLL_vUTPCustomer.FindLastCycleByCompanyId(rctxtCompany.SelectedValue, this.OrderBy);

            whereStr = " and it.CompanyID='" + rctxtCompany.SelectedValue + "' and it.Cycle >= " +
                       rctxtStartingCycle.SelectedValue + " and it.Cycle <= " + endingCycle.Cycle + "";

            vUTPCycleObjs = BLL_vUTPCustomer.GetUTPCycles(whereStr, this.OrderBy);

            if (vUTPCycleObjs.Count() > 0)
            {
                rctxtEndingCycle.DataSource     = vUTPCycleObjs;
                rctxtEndingCycle.DataValueField = "Cycle";
                rctxtEndingCycle.DataTextField  = "Cycle";
                rctxtEndingCycle.DataBind();
            }
        }
    }
    protected void CycleComboBoxBind(string UTPCompanyId)
    {
        RadComboBoxItem startingCycle; //起始区域Telerik控件
        RadComboBoxItem endingCycle;   //结束区域Telerik控件
        string          whereStr;

        whereStr     = " and it.CompanyID='" + UTPCompanyId + "'";
        this.OrderBy = " it.Cycle asc ";

        try
        {
            vUTPCycleObjs = BLL_vUTPCustomer.GetUTPCycles(whereStr, this.OrderBy);
        }
        catch (NullReferenceException)
        {
            BLL_vUTPCustomer = new vUTPCustomerBLL();
            vUTPCycleObjs    = BLL_vUTPCustomer.GetUTPCycles(whereStr, this.OrderBy);
        }

        if (vUTPCycleObjs.Count() > 0)
        {
            try
            {
                //起始区域
                rctxtStartingCycle.DataSource     = vUTPCycleObjs;
                rctxtStartingCycle.DataValueField = "Cycle";
                rctxtStartingCycle.DataTextField  = "Cycle";
                rctxtStartingCycle.DataBind();

                //终止区域
                rctxtEndingCycle.DataSource     = vUTPCycleObjs;
                rctxtEndingCycle.DataValueField = "Cycle";
                rctxtEndingCycle.DataTextField  = "Cycle";
                rctxtEndingCycle.DataBind();
            }
            catch (Exception)
            {
                //清空终止区域
                rctxtEndingCycle.Items.Clear();

                endingCycle = new RadComboBoxItem("N/A", "N/A");
                rctxtEndingCycle.Items.Add(endingCycle);

                //清空起始区域
                rctxtStartingCycle.Items.Clear();

                startingCycle = new RadComboBoxItem("N/A", "N/A");
                rctxtStartingCycle.Items.Add(startingCycle);
            }
        }
        else
        {
            //清空终止区域
            rctxtEndingCycle.Items.Clear();

            endingCycle = new RadComboBoxItem("N/A", "N/A");
            rctxtEndingCycle.Items.Add(endingCycle);

            //清空起始区域
            rctxtStartingCycle.Items.Clear();

            startingCycle = new RadComboBoxItem("N/A", "N/A");
            rctxtStartingCycle.Items.Add(startingCycle);

            //无数据chkAllCycles置灰
            chkAllCycles.Checked = false;
            chkAllCycles.Enabled = false;
        }
    }