protected void Page_Load(object sender, EventArgs e) { this.claimSkuId = Common.GetEncryptedQueryStringValue("ClaimSkuId", 0); this.storeId = Common.GetEncryptedQueryStringValue("StoreId", 0); this.accountId = Common.GetEncryptedQueryStringValue("AccountId", 0); this.supplier = Common.GetEncryptedQueryStringValue("Supplier", ""); this.accountId = (this.accountId == 0) ? (Account.GetAccountByUserName(Page.User.Identity.Name.ToString()).AccountId) : this.accountId; LabelPageTitle.Text = (this.claimSkuId == 0) ? "New Claim by Sku" : "Edit Claim by Sku"; PanelError.Visible = false; Page.Form.DefaultFocus = DropDownListStore.ClientID; Page.Form.DefaultButton = ButtonSaveList.UniqueID; if (!IsPostBack) { DropDownListStore.Focus(); BindSupplier(); BindStore(); if (ViewState["ClaimSkuId"] != null) { this.claimSkuId = Convert.ToInt32(ViewState["ClaimSkuId"].ToString()); } if (ViewState["StoreId"] != null) { this.storeId = Convert.ToInt32(ViewState["StoreId"].ToString()); } if (ViewState["AccountId"] != null) { this.accountId = Convert.ToInt32(ViewState["AccountId"].ToString()); } if (this.claimSkuId != 0) { BindClaimSku(); BindClaimSkuCategory(); //FormCategorySetup(); BindSkuCategory(); PanelCaptureDate.Visible = true; } else { PanelCaptureDate.Visible = false; PanelCategory.Visible = false; ButtonDelete.Visible = false; ButtonSaveList.Visible = false; this.accountId = Account.GetAccountByUserName(Page.User.Identity.Name.ToString()).AccountId; } } }