Jaya Prakash

Jaya Prakash

  • 548
  • 2.3k
  • 63.3k

How can i Catch Data Field values

Apr 28 2023 12:26 PM

my grid view

i just want to show this data in a modal popup  

<asp:BoundField ItemStyle-Wrap="false" DataField="BeneficiaryID" HeaderText="BeneficiaryID" />

<asp:BoundField ItemStyle-Wrap="false" DataField="BeneficiaryCode" HeaderText="BeneficiaryCode"/>

<asp:BoundField ItemStyle-Wrap="false" DataField="BankName" HeaderText="BankName"/>
<asp:BoundField ItemStyle-Wrap="false" DataField="IFSC" HeaderText="IFSC"/>
<asp:BoundField ItemStyle-Wrap="false" DataField="AccountNumber" HeaderText="AccountNumber"/>
 <asp:BoundField ItemStyle-Wrap="false" DataField="BeneficiaryName" HeaderText="BeneficiaryName" />

<asp:BoundField ItemStyle-Wrap="false" DataField="TransactionStatus" HeaderText="TransactionStatus"/>

<asp:BoundField ItemStyle-Wrap="false" DataField="Userid" HeaderText="Userid"/>
<asp:BoundField ItemStyle-Wrap="false" DataField="APIPartnerID" HeaderText="APIPartnerID"/>
<asp:BoundField ItemStyle-Wrap="false" DataField="NameAsPerBank" HeaderText="NameAsPerBank"/>
<asp:BoundField ItemStyle-Wrap="false" DataField="Validated" HeaderText="Validated" />

<asp:BoundField ItemStyle-Wrap="false" DataField="AccVerifyTransactionID" HeaderText="AccVerifyTransactionID"/>

<asp:BoundField ItemStyle-Wrap="false" DataField="Status" HeaderText="Status"/>
<asp:BoundField ItemStyle-Wrap="false" DataField="CreatedDatetime" HeaderText="CreatedDatetime"/>
<asp:BoundField ItemStyle-Wrap="false" DataField="username" HeaderText="username"/>

i trying to bind data field vales in a popup 

popup is displaying but data fileds are not displaying help me pls

this is my pop up but values are not binding

protected void ddlshowtop_SelectedIndexChanged(object sender, EventArgs e)
{
    lblBenName.Text = (grdvwMerchantBanks.SelectedRow.FindControl("BeneficiaryName") as TextBox).Text;
    lblbnkName.Text = (grdvwMerchantBanks.SelectedRow.FindControl("BankName") as Label).Text;
    lblBacNum.Text = (grdvwMerchantBanks.SelectedRow.FindControl("AccountNumber") as Label).Text;
    lblIfsc.Text = (grdvwMerchantBanks.SelectedRow.FindControl("IFSC") as Label).Text;
    lblNaPp.Text = (grdvwMerchantBanks.SelectedRow.FindControl("NameAsPerBank") as Label).Text;
    Mpe.Show();
}
protected void lnkDetails_Click(object sender, EventArgs e)
{
}
protected void grdvwMerchantBanks_RowCommand(object sender, GridViewCommandEventArgs e)
{
    if (e.CommandName.Equals("Select"))
    {
        Mpe.Show();
        int index = Convert.ToInt32(e.CommandArgument);
        GridViewRow row = grdvwMerchantBanks.Rows[index];
        ImageButton ImageButton1 = (ImageButton)row.FindControl("imagepop");
    }
}

 


Answers (2)