Answer: We can use
System.IO.File class GetAttributes static method to get the file attributes.
For Example:-
FileAttributes fa = System.IO.File.GetAttributes("file_name_path");
It has enum values like Hidden,Readonly and so on.
Asked In: Many Interviews |
Alert Moderator