C# Corner
Tech
News
Videos
Forums
Trainings
Books
Events
More
Interviews
Jobs
Live
Learn
Career
Members
Blogs
Challenges
Certifications
Bounties
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Refer
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
Verify path is directory or file in C#
WhatsApp
Hiren Soni
13y
8.2
k
0
0
25
Blog
string path=@"C:\Desktop";
if (System.IO.Directory.Exists(path))
{
MessageBox.Show("Directory");
}
if(System.IO.File.Exists(path))
{
MessageBox.Show("File");
}
People also reading
Membership not found