Solved

New-Object : Cannot find an overload for "FileSystemAccessRule" and the argument count: "4".

Posted on 2016-08-04
1
130 Views
Last Modified: 2016-08-04
I am trying to add object inherit and container inherit to a permission statement but I keep getting the error "cannot find an overload for filesustemaccessrule and the argument count:4"  I cant seem to find a solution to the issue.

$Ar = New-Object system.security.accesscontrol.filesystemaccessrule ("$($FirstName[0])$($LastName)","Modify","ObjectInherit","ContainerInherit","Allow")

Open in new window

0
Comment
Question by:Roccat
1 Comment
 

Accepted Solution

by:
Roccat earned 0 total points
ID: 41743440
This works. I am not sure why this works and not the code above

$Ar = New-Object system.security.accesscontrol.filesystemaccessrule ("$($FirstName[0])$($LastName)","Modify", "ContainerInherit, ObjectInherit", "None", "Allow")

Open in new window

0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Set OWA language and time zone in Exchange for individuals, all users or per database.
A procedure for exporting installed hotfix details of remote computers using powershell
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question