I have used the below code to get the existence of different extension files in a drectory.
FileInfo[] projFiles = new string[] { "*.csproj", "*.vbproj", "*.master", "*.aspx", "*.config", "*.ascx", "*.resx" }.SelectMany(i => projectInfo.GetFiles(i, SearchOption.AllDirectories)).Distinct().ToArray();
And used the below code to get the files with path.
FileInfo[] csprojFiles =projectInfo.GetFiles("*.csproj", SearchOption.AllDirectories);
FileInfo[] vbprojFiles = projectInfo.GetFiles("*.vbproj", SearchOption.AllDirectories);
FileInfo[] masterFiles = projectInfo.GetFiles("*.master", SearchOption.AllDirectories);
FileInfo[] aspxFiles = projectInfo.GetFiles("*.aspx", SearchOption.AllDirectories);
Could anyone please help me how to get the mutiple extension files with the path with single line of code as like what i did for existence of multiple extension files in a directory.
Thanks in Advance!!!