have a gridview, when click on row, then row updating event occure, on which i find values from grid, and want to show them in bootstrap popup. Pls help
protected void grdshortlist_RowUpdating(object sender, GridViewUpdateEventArgs e)
{
try
{
var index = e.RowIndex;
GridViewRow row = grdshortlist.Rows[index];
lblcandidateid.Text = grdshortlist.DataKeys[row.RowIndex].Values[0].ToString();
lblappid.Text = grdshortlist.DataKeys[row.RowIndex].Values[1].ToString();
IDataReader dr2 = sql.getdr("select candidates.*,applications.jobid,applications.feedback,applications.jobid,convert(varchar(20),applications.date,113) as date,jobs.role,jobs.location from candidates join applications on candidates.candidateid=applications.candidateid join jobs on jobs.jobid=applications.jobid where applications.applicationid='" + lblappid.Text + "' ");
// lblname.Text = dr2["name"].ToString();
lblemail.Text = dr2["email"].ToString();
lblph.Text = dr2["ph"].ToString();
lbldesig.Text = dr2["designation"].ToString();
lblemployer.Text = dr2["employer"].ToString();
pnlpopup.Visible = true;
ClientScript.RegisterStartupScript(this.GetType(), "Pop", "openModal();", true);
}
catch
{}
}
i tried this, but not working for me when i click on gridview row.
<script type="text/javascript">
function openModal() {
$('[id*=myModal]').modal('show');
}
</script>