<asp:TemplateField HeaderText="Associate ID"> <ItemTemplate> <asp:LinkButton ID="lnkAssId" Text='<%# Eval("associate_id") %>' runat="server" onclick="lnkAssId_Click">LinkButton</asp:LinkButton> </ItemTemplate> </asp:TemplateField> protected void lnkAssId_Click(object sender, EventArgs e) { for (int i = 0; i < grdApproval.Rows.Count; i++) { LinkButton lblAssId = (LinkButton)grdApproval.Rows[i].FindControl("lnkAssId"); Session["AssId"] = lblAssId.Text; } }
protected void lnkAssId_Click(object sender, EventArgs e) { string lnkAssId = (e.Item as GridDataItem).GetDataKeyValue("lnkAssId").ToString(); Session["AssId"] = lblAssId.Text; }
foreach (GridViewRow row in gridDelivery.Rows) { CheckBox checkPRNNo = (CheckBox)row.FindControl("checkPRNNo"); TextBox txtInvoiceno = (TextBox)row.FindControl("txtInvoiceno"); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)