Answers for "check if any file exists in a directory c#"

C#
10

c# file exist

if (File.Exists("file.exe"))
{
	//file exist
} else {
  //does not exist
}
Posted by: Guest on March-02-2020
1

check if file exist c#

if(File.Exists(@"C:file.exe"))
{
    Console.WriteLine("This file exists!");
}
else
{
  Console.WriteLine("This file does not exist!");
}
Posted by: Guest on September-29-2021

Code answers related to "check if any file exists in a directory c#"

C# Answers by Framework

Browse Popular Code Answers by Language