Answers for "c# get file extension"

C#
1

c# get file extension

string myFilePath = @"C:\MyFile.txt";
string ext = Path.GetExtension(myFilePath);
// ext would be ".txt"
Posted by: Guest on August-11-2020
3

csharp file extension

// .CS is C#'s file extension, although (on windows)
// the final output will result in the form of a .EXE or a .DLL
Posted by: Guest on February-06-2021

C# Answers by Framework

Browse Popular Code Answers by Language