dir Z:在cmd中工作但在PowerShell中失败。
我需要这个脚本。
我做错了什么?
PowerCLI C:\> Get-ChildItem Z:
Get-ChildItem : Cannot find drive. A drive with the name 'Z' does not exist.
At line:1 char:1
+ Get-ChildItem Z:
+ ~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (Z:String) [Get-ChildItem], DriveNotFoundException
+ FullyQualifiedErrorId : DriveNotFound,Microsoft.PowerShell.Commands.GetChildItemCommand