Get-Variable [[-Name] <String[]>] [-ValueOnly] [-Include <String[]>] [-Exclude <String[]>] [-Scope <String>] [<CommonParameters>]说明Get-Variable cmdlet 获取当前控制台中的 PowerShell 变量。可以通过指定 ValueOnly 参数来仅检索变量的值,并且可以按名称筛选返回的变量。示例...
Get-Variable [[-Name] <String[]>] [-ValueOnly] [-Include <String[]>] [-Exclude <String[]>] [-Scope <String>] [<CommonParameters>]说明cmdlet Get-Variable 获取当前控制台中的 PowerShell 变量。通过指定 ValueOnly 参数可以只检索这些变量的值,还可以按名称筛选返回的变量。示例...
Get-ADGroup:获取活动目录中组对象的信息。 Get-ADOrganizationalUnit:获取活动目录中组织单位对象的信息。 Get-ADDomainController:获取活动目录中域控制器的信息。 Get-ADUserResultantPasswordReplicationPolicy:获取活动目录中用户对象的密码复制策略信息。 Get-ADFineGrainedPasswordPolicy:获取活动目录中的细粒度密码策略信息。
不能够显示它的其它信息,如果想查看一个变量的其它保留信息,就需要变量的基类PSVariable对象,这个可以通过Get-Variable命令得到,下面的例子演示如何查看一个变量的全部信息。 1、修改变量的选项设置 Powershell处理一个变量的PSVariable对象,主要是为了能够更新变量的选项设置。既可以使用命令Set-Variable,也可以在获取PSvar...
Get-ChildItem Variable: 还可以使用 Get-Variable cmdlet 查看内存中的变量: PowerShell 复制 Get-Variable 备注 Windows PowerShell 包含多个 cmdlet,用于创建、操作和查看变量。 但很少会使用这些变量,因为可以直接创建和操作变量,而无需使用 cmdlet。 因此,本课程仅简要介绍了用于操作变量的 cmdlet。下...
GetRunspaceCommand GetRunspaceDebugCommand GetSecureRandomCommand GetServiceCommand GetTimeZoneCommand GetTraceSourceCommand GetTypeDataCommand GetUICultureCommand GetUniqueCommand GetUptimeCommand GetVariableCommand GetVariableCommand Constructors Properties Exclude Include Name ValueOnly Methods GetVerbCommand GetWinE...
WhatIf, Confirm,Verbose,Debug,Warn,ErrorAction,ErrorVariable,OutVariable和OutBuffer 三丶powershell 别名命令使用 3.1 别名 powershell支持别名,可以通过别名来引用此命令。 例如: clear-host 是powershell内部函数,表示清空命令窗口 它的别名有 cls clear等,powershell会自动识别,并且运行 Clear-host ...
Get-ChildItem [[-Filter] <string>] -LiteralPath <string[]> [-Include <string[]>] [-Exclude <string[]>] [-Recurse] [-Depth <uint>] [-Force] [-Name] [<CommonParameters>]说明Get-ChildItem cmdlet 获取一个或多个指定位置中的项。 如果该项为容器,则此命令将获取容器内的各项(称为子项)。
Get-WinEvent 参考 反馈 模块: Microsoft.PowerShell.Diagnostics 获取本地和远程计算机上的事件日志和事件跟踪日志文件中的事件。 语法 PowerShell复制 Get-WinEvent[[-LogName] <String[]>] [-MaxEvents <Int64>] [-ComputerName <String>] [-Credential <PSCredential>] [-FilterXPath <String>] [-Force] [...
Get-Help Start-Service -Parameter * Start-Service cmdlet 的帮助显示,只有 InputObject 和名称参数接受管道输入。 Output 复制 -InputObject <ServiceController[]> Specifies ServiceController objects representing the services to be started. Enter a variable that contains the objects, or type a command or...