protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { fillWarehouse(); if (Session["TRID"] != null) { if (Session["TRID"].ToString() != "0" && Session["TRstate"].ToString() == "View") { state = "View"; GetTransferDetails(Session["TRID"].ToString()); } else if (Session["TRID"].ToString() == "0" && Session["TRstate"].ToString() == "Add") { state = "Add"; fillUser(); WMpageAddNew(); ddlWTWStatus.DataSource = WMFillStatus(); ddlWTWStatus.DataBind(); UCWTWTransferDate.Date = DateTime.Now; UC_ShippingDate.Date = DateTime.Now; UCExpDeliveryDate.Date = DateTime.Now; } } } Toolbar1.SetAddNewRight(false, "Not Allowed"); Toolbar1.SetEditRight(false, "Not Allowed"); Toolbar1.SetSaveRight(true, "Not Allowed"); Toolbar1.SetClearRight(false, "Not Allowed"); Toolbar1.SetImportRight(false, "Not Allowed"); }
protected void divDisabled() { if (ddlStatus.Items.Count > 0) { if (Convert.ToInt32(ddlStatus.SelectedItem.Value) > 1) { ScriptManager.RegisterStartupScript(this, this.GetType(), "changemodeIssue" + Session.SessionID, "changemode(true, 'divIssueDetail')", true); Toolbar1.SetSaveRight(false, "Not Allowed"); Toolbar1.SetClearRight(false, "Not Allowed"); Toolbar1.SetEditRight(false, "NotAllowed"); PopUP.Visible = false; } //else { ScriptManager.RegisterStartupScript(this, this.GetType(), "changemodeIssue" + Session.SessionID, "changemode(false, 'divIssueDetail')", true); } } }
protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { if (Session["QCID"] != null) { if (Session["QCID"].ToString() != "0" && Session["QCstate"].ToString() == "View") { state = "View"; GetDispatchDetails(Session["QCID"].ToString()); } else if (Session["QCID"].ToString() != "0" && Session["QCstate"].ToString() == "Edit") { state = "Edit"; fillUser(); ddlStatus.DataSource = WMFillStatus(); ddlStatus.DataBind(); UCDispatchDate.Date = DateTime.Now; UC_ShippingDate.Date = DateTime.Now; UCExpDeliveryDate.Date = DateTime.Now; if (Session["QCID"].ToString() != "0") { DisplaySOData(); } } } else if (Session["DispID"] != null) { if (Session["DispID"].ToString() != "0" && Session["Dispstate"].ToString() == "View") { state = "View"; GetDispatchDetails(Session["DispID"].ToString()); } } else if (Session["TRID"] != null) { if (Session["TRID"].ToString() != "0" && Session["TRstate"].ToString() == "View") { state = "View"; GetDispatchDetails(Session["TRID"].ToString()); } else if (Session["TRID"].ToString() != "0" && Session["TRstate"].ToString() == "Edit") { state = "Edit"; fillUser(); ddlStatus.DataSource = WMFillStatus(); ddlStatus.DataBind(); UCDispatchDate.Date = DateTime.Now; UC_ShippingDate.Date = DateTime.Now; UCExpDeliveryDate.Date = DateTime.Now; if (Session["TRID"].ToString() != "0") { DisplaySOData(); } } } } Toolbar1.SetAddNewRight(false, "Not Allowed"); Toolbar1.SetEditRight(false, "Not Allowed"); if (state != "View") { Toolbar1.SetSaveRight(true, "Not Allowed"); } else { Toolbar1.SetSaveRight(false, "Not Allowed"); } Toolbar1.SetClearRight(false, "Not Allowed"); Toolbar1.SetImportRight(false, "Not Allowed"); }