Examveda

What is the purpose of the Directory.GetFiles() method in C#?

A. Moves all files from one directory to another

B. Deletes all files in a specified directory

C. Retrieves the names of files in a specified directory that match a specified pattern

D. Retrieves the names of all files in a specified directory

Answer: Option C


Join The Discussion

Related Questions on File Handling and Input Output in C Sharp