Skip to content

Latest commit

 

History

History
267 lines (191 loc) · 6.31 KB

New-CMGlobalConditionXPathQuery.md

File metadata and controls

267 lines (191 loc) · 6.31 KB
description external help file Module Name ms.date schema title
Creates a XPath Query type global condition in Configuration Manager.
AdminUI.PS.dll-Help.xml
ConfigurationManager
01/08/2019
2.0.0
New-CMGlobalConditionXPathQuery

New-CMGlobalConditionXPathQuery

SYNOPSIS

Creates a XPath Query type global condition in Configuration Manager.

SYNTAX

NewQueryFromFile (Default)

New-CMGlobalConditionXPathQuery -DataType <GlobalConditionDataType> [-IncludeSubfolder <Boolean>]
 [-Is64Bit <Boolean>] -XmlFilePath <String> [-XmlNamespace <String[]>] -XPathQueryFilePath <String>
 [-Description <String>] -Name <String> [-DisableWildcardHandling] [-ForceWildcardHandling]
 [<CommonParameters>]

NewQueryFromText

New-CMGlobalConditionXPathQuery -DataType <GlobalConditionDataType> [-IncludeSubfolder <Boolean>]
 [-Is64Bit <Boolean>] -XmlFilePath <String> [-XmlNamespace <String[]>] -XPathQuery <String>
 [-Description <String>] -Name <String> [-DisableWildcardHandling] [-ForceWildcardHandling]
 [<CommonParameters>]

DESCRIPTION

The New-CMGlobalConditionXPathQuery cmdlet creates a XPath Query type global condition in Configuration Manager.

A global condition is a setting or expression in Configuration Manager that you can use to specify how Configuration Manager provides and deploys an application to clients.

Note

Run Configuration Manager cmdlets from the Configuration Manager site drive, for example PS XYZ:\>. For more information, see getting started.

EXAMPLES

Example 1

PS XYZ:\> $GlobalXpath = New-CMGlobalConditionXPathQuery -DataType String -XmlFilePath "c:\A" -XPathQuery "/" -Name GC8

This command creates a XPath Query type global condition in Configuration Manager.

PARAMETERS

-DataType

Specifies a data type.

Type: GlobalConditionDataType
Parameter Sets: (All)
Aliases:
Accepted values: String, DateTime, Integer, FloatingPoint, Version, Boolean

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Description

Specifies a description.

Type: String
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-DisableWildcardHandling

This parameter treats wildcard characters as literal character values. You can't combine it with ForceWildcardHandling.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ForceWildcardHandling

This parameter processes wildcard characters and may lead to unexpected behavior (not recommended). You can't combine it with DisableWildcardHandling.

Type: SwitchParameter
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-IncludeSubfolder

Enable this option if you also want to search any sub-folders under the specified path.

Type: Boolean
Parameter Sets: (All)
Aliases: IncludeSubfolders

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Is64Bit

Indicate whether the 64-bit system file location (%windir%\system32) should be searched in addition to the 32-bit system file location (%windir%\syswow64) on Configuration Manager clients that run a 64-bit version of Windows.

Type: Boolean
Parameter Sets: (All)
Aliases:

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Name

Specifies a name.

Type: String
Parameter Sets: (All)
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-XmlFilePath

Specifies the path to the XML file on client computers that will be used to assess compliance. Configuration Manager supports the use of all Windows system environment variables and the %USERPROFILE% user variable in the path name.

Type: String
Parameter Sets: (All)
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-XmlNamespace

Specifies namespaces to use during the XPath query.

Type: String[]
Parameter Sets: (All)
Aliases: XmlNamespaces

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-XPathQuery

Specifies a valid full XML path language (XPath) query to use to assess compliance on client computers.

Type: String
Parameter Sets: NewQueryFromText
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-XPathQueryFilePath

Specifies an XPath query file path.

Type: String
Parameter Sets: NewQueryFromFile
Aliases:

Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

None

OUTPUTS

System.Object

NOTES

RELATED LINKS

Set-CMGlobalConditionXPathQuery

New-CMGlobalCondition

New-CMGlobalConditionActiveDirectoryQuery

New-CMGlobalConditionAssembly

New-CMGlobalConditionFile

New-CMGlobalConditionIisMetabase

New-CMGlobalConditionOmaUri

New-CMGlobalConditionRegistryKey

New-CMGlobalConditionRegistryValue

New-CMGlobalConditionScript

New-CMGlobalConditionSqlQuery

New-CMGlobalConditionWqlQuery