protected void LB_Exportar_Click(object sender, EventArgs e) { Table TablaAExcel = new Table(); tablaExpor = new ExporTabla(idCOnvocatoria); tablaExpor._Tabla = (Table)Session["P_TablaEval"]; tablaExpor.BorrarControl(); TablaAExcel = tablaExpor._TablaAExcel1; exportar(TablaAExcel); }
/// <summary> /// Handles the Click event of the LB_Exportar control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="EventArgs"/> instance containing the event data.</param> protected void LB_Exportar_Click(object sender, EventArgs e) { var indicefila = ((GridViewRow)((Control)sender).NamingContainer).RowIndex; GridViewRow filaGrilla = GV_Actas.Rows[indicefila]; Int64 idConvocatoria = Int64.Parse(GV_Actas.DataKeys[filaGrilla.RowIndex].Value.ToString()); ExporTabla tablaExpor = new ExporTabla("" + idConvocatoria); tablaExpor.llenarData(); tablaExpor.crearTabla(); Table TablaAExcel = new Table(); tablaExpor.BorrarControl(); TablaAExcel = tablaExpor._TablaAExcel1; exportar(TablaAExcel, "" + idConvocatoria); }