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 chkAllCycles_CheckedChanged(object sender, EventArgs e)
    {
        this.OrderBy = " it.Cycle asc";

        vUTPCycle startingCycle;//��ʼ����
        vUTPCycle endingCycle;//��ֹ����

        string vUTPCompanyId;

        if (chkAllCycles.Checked==true)
        {
            vUTPCompanyId=rctxtCompany.SelectedValue;
            if (vUTPCompanyId != "N/A" && !rctxtEndingCycle.SelectedValue.Equals("N/A")
                                            && !rctxtStartingCycle.SelectedValue.Equals("N/A"))
            {
                BLL_vUTPCustomer = new vUTPCustomerBLL();
                startingCycle = BLL_vUTPCustomer.FindFirstCycleByCompanyId(vUTPCompanyId, this.OrderBy);
                endingCycle = BLL_vUTPCustomer.FindLastCycleByCompanyId(vUTPCompanyId, this.OrderBy);

                //���ռ丳ֵ
                rctxtStartingCycle.SelectedValue = startingCycle.Cycle.ToString().Trim();

                rctxtEndingCycle.SelectedValue = endingCycle.Cycle.ToString().Trim();

                //����ؼ��û�
                rctxtEndingCycle.Enabled = false;
                rctxtStartingCycle.Enabled = false;
            }
        }
        else
        {
            rctxtEndingCycle.Enabled = true;
            rctxtStartingCycle.Enabled = true;
        }
    }