title: vb.net GridView store value but display text from datatable
body: <p>Please I want to store the value of address in the gridview or datatable but display it's name, so when saving data to database I will insert the value.</p>
  
  <pre><code>    dtCust_dtls.DefaultView.RowFilter = String.Format("SR_ID = '{0}'", SrLookup.GetSelectedItem("SR_ID"))
      GCCustList.DataSource = dtCust_dtls.DefaultView
  
      GVCustList.Columns("CUSTOMER_CODE").VisibleIndex = 0
      GVCustList.Columns("ADDRESS_ID").VisibleIndex = 1
      GVCustList.Columns("CUSTOMER_CODE").Caption = "Customer Code"
      GVCustList.Columns("ADDRESS_ID").Caption = "Address"
  </code></pre>
  
  <p>on button add</p>
  
  <pre><code>  dtCust_dtls.DefaultView.RowFilter = String.Format("SR_ID = '{0}' and CUSTOMER_CODE = '{1}'", SrLookup.GetSelectedItem("SR_ID"), txtCust_Code.Text.Trim)
      If (dtCust_dtls.DefaultView.Count = 0) Then
          Dim dr As DataRow = dtCust_dtls.NewRow()
          dr("SR_ID") = SrLookup.GetSelectedItem("SR_ID")
          dr("CUSTOMER_ID") = DataRowSelectedCust("CUSTOMER_ID")
          dr("ADDRESS_ID") = cmbCustAdd.SelectedValue
          dr("CUSTOMER_CODE") = txtCust_Code.Text.Trim
          dr("CUSTOMER_BARCODE") = DataRowSelectedCust("CUSTOMER_ID") &amp; "." &amp; cmbCustAdd.SelectedValue 'custId + . + addID
          dr("STAMP_DATE") = Now
          dtCust_dtls.Rows.Add(dr)
      Else
          MsgBox("The Customer code '" &amp; txtCust_Code.Text &amp; "' already exist for " &amp; txtSrName.Text)
      End If
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/EAMMh.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/EAMMh.jpg" alt="enter image description here"></a></p>
  
  <p>on save btn I am saving the datatable dtCust_dtls as it is.</p>
  
  <p>I had an idea to add one column : Address Name and leave the column Address ID but I don't have any idea how to do it !</p>