Possibility to use AddUsersToPFRecursive.ps1 not at TOP folder.

Hi everyone, I would like to know if I can use AddUsersToPFRecursive.ps1 not at TOP folder. We have lot of projects in top folder "\Projets" but inside theses projects folder I would like to do recursive to SUB folder "\Projects\folder1" and maybe if it's possible to do add a user to all "Administration in all "folderX" under Project"
 
"\Projects"
 "\Projects\folderA\test"
 "\Projects\folderA\ok"
 "\Projects\folderA\Administration"  <-------
 "\Projects\folderB\test"
 "\Projects\folderB\ok"
 "\Projects\folderB\Administration"  <-------

do you know any possibility to do that using this AddUsersToPFRecursive.ps1 or something else.

thank you
PRAAAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

PRAAAuthor Commented:
I have found a MS software PFDAVAdmin but when I try to get it work in "Propagate ACEs" with the option "Apply only to folders named:" checked I got

See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.
************** Exception Text **************
System.Exception: Invalid filter string. Index was outside the bounds of the array.
   at pfdavadmin.FolderFilter.GetConditionsFromString(String& filterString)
   at pfdavadmin.FolderFilter.BuildFilterFromString(String filterString)
   at pfdavadmin.Form1.PropagateAce(TreeNode selectedNode)
   at pfdavadmin.Form1.PropagateMenu_Clicked(Object sender, EventArgs e)
   at System.Windows.Forms.MenuItem.OnClick(EventArgs e)
   at System.Windows.Forms.MenuItemData.Execute()
   at System.Windows.Forms.Command.Invoke()
   at System.Windows.Forms.Control.WmCommand(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.TreeView.WndProc(Message& m)
   at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

************** Loaded Assemblies **************
mscorlib
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.2407
    CodeBase: file:///c:/windows/microsoft.net/framework/v1.1.4322/mscorlib.dll
----------------------------------------
PFDAVAdmin
    Assembly Version: 6.5.0.0
    Win32 Version: 6.5.7911.0
    CodeBase: file:///C:/PFDAVAdmin/PFDAVAdmin.exe
----------------------------------------
System.Windows.Forms
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.2032
    CodeBase: file:///c:/windows/assembly/gac/system.windows.forms/1.0.5000.0__b77a5c561934e089/system.windows.forms.dll
----------------------------------------
System
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.2407
    CodeBase: file:///c:/windows/assembly/gac/system/1.0.5000.0__b77a5c561934e089/system.dll
----------------------------------------
System.Drawing
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.2032
    CodeBase: file:///c:/windows/assembly/gac/system.drawing/1.0.5000.0__b03f5f7f11d50a3a/system.drawing.dll
----------------------------------------
Accessibility
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.573
    CodeBase: file:///c:/windows/assembly/gac/accessibility/1.0.5000.0__b03f5f7f11d50a3a/accessibility.dll
----------------------------------------
System.DirectoryServices
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.2032
    CodeBase: file:///c:/windows/assembly/gac/system.directoryservices/1.0.5000.0__b03f5f7f11d50a3a/system.directoryservices.dll
----------------------------------------
System.Xml
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.2032
    CodeBase: file:///c:/windows/assembly/gac/system.xml/1.0.5000.0__b77a5c561934e089/system.xml.dll
----------------------------------------
E2kfdacl
    Assembly Version: 6.5.0.0
    Win32 Version: 6.5.7911.0
    CodeBase: file:///C:/PFDAVAdmin/E2kfdacl.DLL
----------------------------------------
************** JIT Debugging **************
To enable just in time (JIT) debugging, the config file for this
application or machine (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.
For example:
<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>
When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the machine
rather than being handled by this dialog.
0
Exchange_GeekCommented:
Are you able to use PFDavAdmin to view the PF ? I mean can you view PFs ??
0
PRAAAuthor Commented:
Hi,
Yes I'm able to see the PF and apply recursive security  to the folder I select like I select Projects and apply the security to all like:
"\Projects"
 "\Projects\folderA\test"
 "\Projects\folderA\ok"
 "\Projects\folderA\Administration"
 "\Projects\folderB\test"
 "\Projects\folderB\ok"
 "\Projects\folderB\Administration"

 or  
select Folder A and make it apply to
Test, OK and Administration folder....it work
But if I select "Apply only to folders named:" in PFDavAdmin for all folder named "Administration" under the folder Projects I got the error.
0
Has Powershell sent you back into the Stone Age?

If managing Active Directory using Windows Powershell® is making you feel like you stepped back in time, you are not alone.  For nearly 20 years, AD admins around the world have used one tool for day-to-day AD management: Hyena. Discover why.

Exchange_GeekCommented:
Ok i did the same re-pro at my lab - and guess what - gave the same error LOL

However, i made a command and it works pretty cool.

Get-PublicFolder -Server "E2k7 box" -identity "\Project" | where {$_.name -like "Administration"}

This would give result for all sub folders created within project folder named "Administration".

Once you get this result, you can easily play around with what ever permission you want to append.


0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
PRAAAuthor Commented:
I use the command you made, I get no error but I dont get any information output from it. Do you have experience something like this also?
Get-PublicFolder -Server "E2k7 box" -identity "\Project" | where {$_.name -like "Administration"}

no output

Using this
Get-PublicFolder -Server "E2k7 box" -identity "\Project" | where {$_.name -like "*"}

i got

Name                                                        Parent Path
----                                                        -----------
Project                                                      \
like is not searching in subfolders.

 
0
kjetpettCommented:
add "-recurse" before "| where"
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Exchange

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.