public void regularSave(object source, ElapsedEventArgs e) { String filename = Path.Combine("../../../record/", DateTime.Now.ToString("yyyy_MM_dd_hh") + "_record.csv"); CSVFileHelper.SaveCSV(frequencyTable.frequencies, filename); frequencyTable.clear(); }
/// <summary> /// 导出Csv /// </summary> /// <param name="FilePath"></param> /// <returns></returns> public bool ExportCSV(string FilePath) { if (!CSVFileHelper.SaveCSV(DataHistory, FilePath)) { return(false); } return(true); }
public bool ExportCSV(string filePath, DataTable _data) { if (!CSVFileHelper.SaveCSV(_data, filePath)) { return(false); } return(true); }
/// <summary> /// Save tag file Manually /// </summary> /// <param name="filename">tag file name</param> public void SaveAsCSV(string filename) { SaveFileDialog fileDialog = new SaveFileDialog(); fileDialog.RestoreDirectory = true; fileDialog.InitialDirectory = _filepath; fileDialog.Filter = "CSV文件|*.csv*|XML文件|*.xml"; fileDialog.FileName = filename.Substring(1, filename.Length - 1); fileDialog.RestoreDirectory = true; if (fileDialog.ShowDialog() == DialogResult.OK) { CSVFileHelper.SaveCSV(_tagsTable.Tags, fileDialog.FileName); TagsWithPosTable tagsWithPosTable = PhaseLocating.getInstance().tagsWithPosTable; CSVFileHelper.SaveCSV(tagsWithPosTable.tags, fileDialog.FileName + "WithPos.csv"); } }
public void Save(string path) { CSVFileHelper.SaveCSV(m_dt, path); }
/// <summary> /// Save tag file automatically /// </summary> /// <param name="filename">tag file name</param> public void SaveCSV(string filename) { CSVFileHelper.SaveCSV(_tagsTable.Tags, _filepath + filename); }