Solved

powershell v2 doesn't respond to <f> keys, and doesn't recognize some parameter names

Posted on 2014-09-03
2
161 Views
Last Modified: 2014-09-18
I'm trying to get a list of permissions on all subdirectories and files, and output that permissions list to a file

I use     Get-Acl          by itself and see what I want on the screen, except that it is truncated to screen width.



       How would you get around this truncation? What I tried below didn't work



To get by the truncation, I figure I'll send it to a file and see if that helps

However, I never get that far; I try to add the out-file parameter and get errors

PS U:\> get-acl out-file -filepath List3
Get-Acl : A parameter cannot be found that matches parameter name 'filepath'.



Also, FYI,  the <f> keys don't work. I press <f7> and get nothing. What's up with that? I recall it used to work.


Thanks



FYI, My data:

PS U:\> $PSVersionTable.PSVersion
Major  Minor  Build  Revision
-----  -----  -----  --------
2      0      -1     -1

I started PS with <Run as Administrator>

Windows 7 Pro SP1  32 bit
0
Comment
Question by:cgunix
2 Comments
 
LVL 39

Assisted Solution

by:footech
footech earned 250 total points
ID: 40301692
You would need  a pipe character for your command to work.
get-acl | out-file -filepath List3
However, that won't change the output here.
Here's a couple simple options for you.
get-acl | ft -auto -wrap
get-acl | fl
0
 
LVL 40

Accepted Solution

by:
Subsun earned 250 total points
ID: 40301699
If you are trying to export the permission details to output file then you can use the following code. You actually need to pipe the results of Get-ACL command to the Export-csv  (to export the result to csv file) or out-file command..
Get-acl C:\windows | Export-Csv C:\temp\report.csv -nti

Open in new window

Or
Get-Acl C:\windows | FL | Out-File c:\temp\report.txt

Open in new window

To show complete details to screen..
Get-Acl C:\windows | FT -auto -Wrap

Open in new window


And if I am not wrong, F7 - just list the history of commands you have already typed in. This is not a particular function for PowerShell. You will get the command history even in cmd console.

If you need an example for exporting permission details using Get-Acl, then refer the following question..
http://www.experts-exchange.com/Programming/Languages/Scripting/Powershell/Q_28230936.html
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

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

How to sign a powershell script so you can prevent tampering, and only allow users to run authorised Powershell scripts
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…

863 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

Need Help in Real-Time?

Connect with top rated Experts

26 Experts available now in Live!

Get 1:1 Help Now