private void export_to_excel() { Dictionary <string, double> Data = new Dictionary <string, double>(); // here i will check whick is not empty and show it //foreach (DataRow row in table.Rows) //{ // //check key exist before in dictionary // // check_and_ADD(ref Data, row[TB_1.Tag.ToString()].ToString(), row[TB_2.Tag.ToString()].ToString()); // // check_and_ADD(ref Data, row[TB_3.Tag.ToString()].ToString(), row[TB_4.Tag.ToString()].ToString()); //} ToExcelC.rowcounts = EIndex; ToExcelC.rowcounts = EIndex; ToExcelC a = new ToExcelC(); //saveFileDialog.Filter = "xlsx file|*.xlsx"; //saveFileDialog.Title = "Capacitorsheet Metering Save To"; //saveFileDialog.ShowDialog(); //if (saveFileDialog.FileName != "") //{ a.export(table, ""); //} saveFileDialog.FileName = ""; }
private void export_to_excel() { Dictionary <string, double> Data = new Dictionary <string, double>(); ToExcelC.rowcounts = EIndex; ToExcelC a = new ToExcelC(); a.export(table, ""); }
private void linkLabel1_LinkClicked_1(object sender, LinkLabelLinkClickedEventArgs e) { AccessDBC a = new AccessDBC(); ToExcelC c = new ToExcelC(); DataTable tablex = new DataTable(); tablex = a.Read_DataSet(null, "Capacitorsheet", "*"); c.ExportToExcel(tablex, "Capacitorsheet"); }
private void linkLabel5_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { AccessDBC.connection_str = AccessDBC.Database_LOC("SMB.accdb"); AccessDBC a = new AccessDBC(); ToExcelC c = new ToExcelC(); DataTable tablex = new DataTable(); List <string> list = new List <string>() { Des14.Tag.ToString(), Des15.Tag.ToString(), Ref1.Tag.ToString() }; tablex = a.Read_DataSet(null, table.Text, list); c.ExportToExcel(tablex, "Flag Relays"); }