protected void btnRegresh_Click(object sender, ImageClickEventArgs e)
 {
     if (!string.IsNullOrEmpty(Customerid.Value))
     {
         int CustID = Convert.ToInt32(Customerid.Value);
         Customer objCust = new Customer();
         CustomerBLL objCBLL = new CustomerBLL();
         objCust.CustomerID = CustID;
         List<Customer> objLCust = objCBLL.GetCustomerDetailByCustID(ref objCust);
         if (null != objLCust)
         {
             PopulateFormFields(objLCust);
         }
     }
     ScriptManager.RegisterStartupScript(this, this.GetType(), "PopulateCustomer", "Populate()", true);
 }
    private void LoadData(int vintCustomerID)
    {
        try
        {
            Customer objCustomer = new Customer();
            CustomerBLL objUBLL = new CustomerBLL();
            objCustomer.CustomerID = vintCustomerID;
            List<Customer> objList = objUBLL.GetCustomerDetailByCustID(ref objCustomer);

            if (null != objList)
            {
                txtFirstName.Text = objList[0].FirstName;
                txtLastName.Text = objList[0].LastName;
                txtAddress.Text = objList[0].Address;
                txtZIP.Text = objList[0].ZIP;
                txtCity.Text = objList[0].City;
                txtCountry.Text = objList[0].Country;
                txtPhone.Text = objList[0].TeleNumber;
                txtEmailID.Text = objList[0].Email;
                txtNote.Text = objList[0].Notes;
                ScriptManager.RegisterStartupScript(this, this.GetType(), "AddEditCustomer", "ShowModalDiv('ModalWindow1','dvInnerWindow',0);", true);

            }
        }
        catch (Exception ex)
        {
            SendMail.MailMessage("CSWeb > Error > " + (new StackTrace()).GetFrame(0).GetMethod().Name, ex.ToString());
        }

    }