protected void Page_Load(object sender, EventArgs e) { if (Session["userid"] == null) { Response.Redirect("~/Login.aspx"); } else { userid = int.Parse(Session["userid"].ToString()); Empname = Session["Empname"].ToString(); BRANCH_ID = int.Parse(Session["Branch_id"].ToString()); } if (Session["client_Id"] != "" && Session["subProcess_id"] != "") { client_Id = int.Parse(Session["client_Id"].ToString()); Subprocess_id = int.Parse(Session["subProcess_id"].ToString()); } if (Session["Ordertype"] != "") { Session_OrderType = Session["Ordertype"].ToString(); if (Session_OrderType == "Web/Call") { LblHeader.Text = "Web/Call Orders Allocation"; } else if (Session_OrderType == "Mail/Fax") { LblHeader.Text = "Mail/Fax Order Allocation"; } else if (Session_OrderType == "QC") { LblHeader.Text = "QC Orders Allocation"; } else if (Session_OrderType == "Hold") { LblHeader.Text = "Client Hold Orders Allocation"; } else if (Session_OrderType == "Clarification") { LblHeader.Text = "Clarification Orders Allocation"; } else if (Session_OrderType == "Cancelled") { LblHeader.Text = "Cancelled Orders Allocation"; } else if (Session_OrderType == "Completed") { LblHeader.Text = "Completed Orders Allocation"; } } if (!IsPostBack) { PopulateTreeview(); Get_Orders_ToAllocate = "CLientAndSubProcess"; ViewState["Order_Allocate"] = Get_Orders_ToAllocate.ToString(); Gridview_Bind_All_Orders(); dbc.BindUserName(ddl_UserName); Restrict_Controls(); btn_Allocate.CssClass = "WebButton"; btn_Allocate.Enabled = false; dbc.BindClientName_Rpt(ddl_ClientName); //Bind_No_of_Allocating_Order(); } }