New-SCSMAnnouncement

Creates an announcement in Service Manager.

Syntax

New-SCSMAnnouncement [-Title] <String> [-ExpirationDate] <DateTime> [-Body <String>] [-ComputerName <String[]>]
 [-Confirm] [-Credential <PSCredential>] [-DisplayName <String>] [-PassThru] [-Priority <String>]
 [-SCSession <Connection[]>] [-WhatIf] [<CommonParameters>]

Description

The New-SCSMAnnouncement cmdlet creates an announcement in Service Manager.

Examples

Example 1: Create an announcement

PS C:\>$Expire = [DateTime]::Now.AddMonths(3)
PS C:\> New-SCSMAnnouncement -Title "A new announcement" -ExpirationDate $Expire -Body "Hello there"

The first command assigns a DateTime object that represents three months in the future to the $Expire variable.

The second command creates a simple announcement that includes a title and text. The command specifies the expiration date stored in $Expire.

Parameters

-Body

Specifies the body of the announcement. This string can be plain text or rich text.

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

Specifies the name of the computer on which the System Center Data Access service runs. The user account that is specified in the Credential parameter must have access rights to the specified computer.

Type:String[]
Required:False
Position:Named
Default value:Localhost
Accept pipeline input:False
Accept wildcard characters:False
-Confirm

Prompts you for confirmation before running the cmdlet.

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

Specifies the credentials that this cmdlet uses to connect to the server on which the System Center Data Access service runs. The specified user account must have access rights to that server.

Type:PSCredential
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DisplayName

Specifies the display name of the announcement.

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

Specifies the expiration date and time of the announcement.

Type:DateTime
Required:True
Position:1
Default value:1/1/3000
Accept pipeline input:False
Accept wildcard characters:False
-PassThru

Indicates that this cmdlet returns the announcement that it creates. You can pass this object to other cmdlets.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Priority

Specifies the priority of the announcement.

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

Specifies an object that represents the session to a Service Manager management server.

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

Specifies the title of the announcement. This is a string that is typically short.

Type:String
Required:True
Position:0
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

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

Inputs

None.

You cannot pipe input to this cmdlet.

Outputs

None.

This cmdlet does not generate any output.