Bewerken

Delen via


Add-CMMobileMsiDeploymentType

Adds a mobile Windows Installer deployment type.

Syntax

Add-CMMobileMsiDeploymentType
   [-InstallCommand <String>]
   [-DeploymentTypeName <String>]
   [-AddRequirement <Rule[]>]
   -ApplicationName <String>
   [-RemoveLanguage <String[]>]
   [-RemoveRequirement <Rule[]>]
   [-AddLanguage <String[]>]
   [-Comment <String>]
   -ContentLocation <String>
   [-Force]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Add-CMMobileMsiDeploymentType
   [-InstallCommand <String>]
   [-DeploymentTypeName <String>]
   [-AddRequirement <Rule[]>]
   -ApplicationId <Int32>
   [-RemoveLanguage <String[]>]
   [-RemoveRequirement <Rule[]>]
   [-AddLanguage <String[]>]
   [-Comment <String>]
   -ContentLocation <String>
   [-Force]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]
Add-CMMobileMsiDeploymentType
   [-InstallCommand <String>]
   [-DeploymentTypeName <String>]
   [-AddRequirement <Rule[]>]
   -InputObject <IResultObject>
   [-RemoveLanguage <String[]>]
   [-RemoveRequirement <Rule[]>]
   [-AddLanguage <String[]>]
   [-Comment <String>]
   -ContentLocation <String>
   [-Force]
   [-DisableWildcardHandling]
   [-ForceWildcardHandling]
   [-WhatIf]
   [-Confirm]
   [<CommonParameters>]

Description

The Add-CMMobileMsiDeploymentType cmdlet adds a mobile Windows Installer deployment type to an application.

Note

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

Examples

Example 1: Add a deployment type

PS XYZ:\>Add-CMMobileMsiDeploymentType -ApplicationName "TestMobile" -ContentLocation "\\Server01\Resources\Applications\MSI\32BitSDK\32BitCompat.msi" -DeploymentTypeName "DTMobile" -AddLanguage "en-US","zh-CN" -Comment "Mobile test"

This command adds the mobile Windows Installer deployment type named DTMobile from the specified location to the application named TestMobile in English and Chinese.

Example 2: Add a deployment type by using the pipeline

PS XYZ:\> Get-CMApplication "TestMobile" | Add-CMMobileMsiDeploymentType -ContentLocation "\\127.0.0.1\c$\UnitTest\Resources\Applications\MSI\32BitSDK\32BitCompat.msi" -DeploymentTypeName "DTMobile02" -AddLanguage "en-US","zh-CN" -Comment "Mobile test"

This command gets the application object named TestMobile and uses the pipeline operator to pass the object to Add-CMMobileMsiDeploymentType. Add-CMMobileMsiDeploymentType adds a mobile Windows Installer deployment type named DTMobile02 from the specified location in English and Chinese.

Parameters

-AddLanguage

Adds an array of languages that this deployment type supports. Provide the languages in the "languagecode2-country" or "languagecode2" format, for example: en, en-US, ja-JP, zh-CN.

For more information, see CultureInfo.Name.

Type:String[]
Aliases:AddLanguages, Languages, Language
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-AddRequirement

Adds an array of requirements for this deployment type.

Type:Rule[]
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ApplicationId

Specifies the ID of the application that is associated with this deployment type.

Type:Int32
Aliases:CI_ID, CIId
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-ApplicationName

Specifies the name of the application that is associated with this deployment type.

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

-Comment

Specifies a description for this deployment type.

Type:String
Aliases:AdministratorComment
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Confirm

Prompts you for confirmation before running the cmdlet.

Type:SwitchParameter
Aliases:cf
Position:Named
Default value:False
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-ContentLocation

Specifies the path to an .msi file. The site system server requires permissions to read the content files.

Type:String
Aliases:InstallationFileLocation
Position:Named
Default value:None
Required:True
Accept pipeline input:False
Accept wildcard characters:False

-DeploymentTypeName

Specifies a display name for this deployment type.

Type:String
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-Force

Forces the command to run without asking for user confirmation.

Type:SwitchParameter
Aliases:ForceForUnknownPublisher
Position:Named
Default value:None
Required:False
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
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-InputObject

Specifies an application object. To obtain an application object, use the Get-CMApplication cmdlet.

Type:IResultObject
Aliases:Application
Position:Named
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-InstallCommand

Specifies the command to use to install the Windows Installer package from the command line.

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

-RemoveLanguage

Removes an array of existing languages from this deployment type. Provide the languages in the "languagecode2-country" or "languagecode2" format, for example: en, en-US, ja-JP, zh-CN.

Type:String[]
Aliases:RemoveLanguages
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-RemoveRequirement

Removes the existing installation requirements from this deployment type.

Type:Rule[]
Aliases:RemoveRequirements
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet doesn't run.

Type:SwitchParameter
Aliases:wi
Position:Named
Default value:False
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Inputs

Microsoft.ConfigurationManagement.ManagementProvider.IResultObject

Outputs

System.Object