使用System.IO.File中的System.IO.File.Exists()方法
if (System.IO.File.Exists(@"文件路径")) { Console.WriteLine("文件存在"); } else { Console.WriteLine("文件不存在.."); }
使用System.IO.File中的System.IO.File.Exists()方法
if (System.IO.File.Exists(@"文件路径")) { Console.WriteLine("文件存在"); } else { Console.WriteLine("文件不存在.."); }