protected void GV_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "Add") { GridView grid = (GridView)sender; DataGridItem item = grid.NamingContainer as DataGridItem; int Doc_No = Convert.ToInt32(gdDrawing.DataKeys[item.ItemIndex]); ViewState["Doc_Id"] = Doc_No; string Material = (grid.FooterRow.FindControl("ddlMaterial_Type") as DropDownList).SelectedItem.Text; int Material_Id = Convert.ToInt32((grid.FooterRow.FindControl("ddlMaterial_Type") as DropDownList).SelectedValue); string Quantity = (grid.FooterRow.FindControl("txtMaterialQty") as TextBox).Text; //material_id = 7 then textbox and linkbutton of footer to set visible as false } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)