Export (0) Print
Expand All

New-MsmqMessage

New-MsmqMessage

This cmdlet creates and returns a new System.Messaging.Message object with properties as specified by the parameters.

Syntax

Parameter Set: Default
New-MsmqMessage [[-Body] <Object> ] [-AdminQueuePath <String> ] [-Authenticated] [-Journaling] [-Label <String> ] [-Recoverable] [-ResponseQueuePath <String> ] [-TimeToBeReceived <TimeSpan> ] [-TimeToReachQueue <TimeSpan> ] [ <CommonParameters>]




Detailed Description

This cmdlet creates and returns a new System.Messaging.Message object with properties as specified by the parameters.

Parameters

-AdminQueuePath<String>

Specifies the queue that receives the acknowledgement messages that Message Queuing generates. Default is empty string.


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Authenticated

If specified, the message is sent as an authenticated message.


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Body<Object>

Specifies the body of the message. Default is empty.


Aliases

none

Required?

false

Position?

1

Default Value

Accept Pipeline Input?

true (ByValue)

Accept Wildcard Characters?

false

-Journaling

If specified, indicates whether a copy of the message should be kept in a machine journal on the originating computer.


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Label<String>

Sets a label that describes the message. Default is empty string.


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Recoverable

If specified, sets the recoverable property of a message object.


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ResponseQueuePath<String>

Specifies the queue that receives application-generated response messages. Default is empty string.


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-TimeToBeReceived<TimeSpan>

Sets the maximum amount of time in milliseconds for the message to be received from the destination queue. Default is 49.17:02:47.295. Alias: TTBR


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-TimeToReachQueue<TimeSpan>

Sets the maximum amount of time in milliseconds for the message to reach the queue. Default is 49.17:02:47.295. Alias: TTRQ


Aliases

none

Required?

false

Position?

named

Default Value

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

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

Examples

Usage Scenario

PS C:\> New-MsmqMessage –Body “Test Message” –Recovarable –AdminQueue “.\private$\adminqueue”

 

 

 



Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft