Question:Given the following code sample, which line correctly finalizes the ACL changes?
Dim dir As String = "C:\MyApp"
Dim ds As DirectorySecurity = Directory.GetAccessControl(dir)
ds.AddAccessRule(New FileSystemAccessRule("Administrator", _
FileSystemRights.FullControl, AccessControlType.Allow))
Directory.SetAccessControl(dir, ds)
 

A Directory.SetAccessControl(dir, ds) 

B Directory.CreateDirectory(dir, ds) 

C Directory.SetAccessControl(ds) 

D Directory.CreateDirectory(ds) 

+ Answer
+ Report
Total Preview: 1099

Copyright © 2024. Powered by Intellect Software Ltd