Ejemplo n.º 1
0
        /// <summary>
        /// Writes a DataTable to file to a path.
        /// </summary>
        /// <param name="data"></param>
        /// <param name="fpath"></param>
        public void WriteCSV(DataTable data, string fpath)
        {
            var writer = new CSVFile.CSVWriter(fpath);

            writer.Write(data, true);
            writer.Dispose();
        }
        /// <summary>
        /// Writes a DataTable to file to a path.
        /// </summary>
        /// <param name="data"></param>
        /// <param name="fpath"></param>
        public void WriteCSV(DataTable data, WriteFileInfo writeFileInfo)
        {
            var writer = new CSVFile.CSVWriter(writeFileInfo.FullPath);

            writer.Write(data, true);
            writer.Dispose();
            executeOnMainThreadQueue.Enqueue(() => onWriteFile.Invoke(writeFileInfo));
        }