private void GunBookCustomer_Load(object sender, EventArgs e) { gunBookCustomerData = GlobalDataAccessor.Instance.DesktopSession.GunBookCustomerData; gunNumber = GlobalDataAccessor.Instance.DesktopSession.GunNumber; customerEditType = GlobalDataAccessor.Instance.DesktopSession.CustomerEditType; if (gunBookCustomerData != null) { currentName.Text = string.Format("{0} {1}", gunBookCustomerData.FirstName, gunBookCustomerData.LastName); customerName.Text = currentName.Text; AddressVO custAddr = gunBookCustomerData.getAddress(0); if (custAddr != null) { address1.Text = custAddr.Address1; address2.Text = string.Format("{0},{1} {2}", custAddr.City, custAddr.State_Code, custAddr.ZipCode); customTextBoxaddr1.Text = custAddr.Address1; customTextBoxAddr2.Text = custAddr.Address2; customTextBoxCity.Text = custAddr.City; ComboBox custstate = (ComboBox)state1.Controls[0]; foreach (USState currstate in custstate.Items) { if (currstate.ShortName == custAddr.State_Code) { custstate.SelectedIndex = custstate.Items.IndexOf(currstate); break; } } zipcode1.Text = custAddr.ZipCode; } customerNumber.Text = gunBookCustomerData.CustomerNumber; labelCustNumber.Text = gunBookCustomerData.CustomerNumber; IdentificationVO custId = gunBookCustomerData.getFirstIdentity(); if (custId != null) { currentID.Text = custId.IdType + " " + custId.IdIssuerCode + " " + custId.IdValue; id.Text = currentID.Text; } newCustomer = Utilities.CloneObject(gunBookCustomerData); GlobalDataAccessor.Instance.DesktopSession.GunAcquireCustomer = this.customerEditType == CustomerType.RECEIPT; } }