コード例 #1
0
 protected void ClearTextFields()
 {
     txtHouseNumber.Text = String.Empty;
     txtStreet.Text      = String.Empty;
     txtCityCounty.Text  = String.Empty;
     DropStateAbb.ClearSelection();
     txtCountryAbb.Text = String.Empty;
     txtZip.Text        = String.Empty;
 }
コード例 #2
0
    protected void GridViewAddress_SelectedIndexChanged(object sender, EventArgs e)
    {
        BtnAddressCommit.Enabled = false;
        BtnUpdate.Enabled        = true;

        addressID           = Convert.ToInt32(GridViewAddress.SelectedRow.Cells[1].Text);
        txtHouseNumber.Text = GridViewAddress.SelectedRow.Cells[2].Text;
        txtStreet.Text      = GridViewAddress.SelectedRow.Cells[3].Text;
        txtCityCounty.Text  = GridViewAddress.SelectedRow.Cells[4].Text;
        string drpText = GridViewAddress.SelectedRow.Cells[5].Text;

        DropStateAbb.ClearSelection();
        DropStateAbb.Items.FindByValue(drpText).Selected = true;
        txtCountryAbb.Text = GridViewAddress.SelectedRow.Cells[6].Text;
        txtZip.Text        = GridViewAddress.SelectedRow.Cells[7].Text;
    }