Username:   Password:  

Read File Permissions in C#

String fullPath = Path.GetFullPathInternal(path);
// For security check, path should be resolved to an absolute path.
new System.Security.Permissions.FileIOPermission(FileIOPermissionAccess.Write, new String[] { fullPath }, false, false ).Demand(); 

Tags

permissions files c#