摘要:Aspose.CellsExcel to datatable 超级快!class Program { private static string _vsPath = @"D:\work\1207\Parametros OMC_new_Marcelo_imported.xlsm"; private static DateTime _vdtStart; static void Main(string[] args) { Workbook workbook = new Workbook(); ... 阅读全文
winform中跨Thread修改ui
2012-12-09 16:55 by hongjiumu, 305 阅读, 0 推荐, 收藏,
摘要:winform中跨Thread修改ui:private Progress GetProgress(Progress progress){this.Invoke((MethodInvoker)delegate() {progressBar1.Value = (int)(progress.PostCount * 99 / progress.TotalCount);progressBar1.Refresh();});return progress;} 阅读全文
What is the fastest, case insensitive, way to see if a string contains another string in C#?
2012-12-01 10:29 by hongjiumu, 200 阅读, 0 推荐, 收藏,
摘要:Since ToUpper would actually result in a new string being created, StringComparison.OrdinalIgnoreCase would be faster, also, regex has a lot of overhead for a simple compare like this. That said, String.IndexOf(String, StringComparison.OrdinalIgnoreCase) should be the fastest, since it does not invo 阅读全文
System.IO.StreamWriter写文件
2012-11-25 12:28 by hongjiumu, 3585 阅读, 0 推荐, 收藏,
摘要:public void WriteFile(string filepath, List<string> list) { int index = 0; System.IO.FileStream fileStream = new System.IO.FileStream(filepath,System.IO.FileMode.Create); System.IO.StreamWriter streamWriter = new System.IO.StreamWriter(fileStream); //streamWriter.Write(content); streamWriter.F 阅读全文
浙公网安备 33010602011771号