private void btnExcel_Click(object sender, EventArgs e) { Configuration config = new Configuration(); using (config) { List <Configuration> configuracion = config.getConfiguration(); DataTable dtbl = maketable(); Export_excel excel = new Export_excel(); excel.ExportToExcel(dtbl, configuracion[0].Ruta_reportes + "/Clientes"); MessageBox.Show("Terminado"); } }
private void button10_Click(object sender, EventArgs e) { if (cboProveedor.Text == "") { MessageBox.Show("Seleccione un proveedor"); } else { Configuration config = new Configuration(); using (config) { List <Configuration> configuracion = config.getConfiguration(); DataTable dtbl = proveedores(); Export_excel excel = new Export_excel(); excel.ExportToExcel(dtbl, configuracion[0].Ruta_reportes + "inventario"); MessageBox.Show("Terminado"); } } }