Short version: is it possible to pass multiple predefined arguments to a powershell function/commandlet?
Since I am not sure about the terms, I cannot find an answer to this. So here is the example, I am using Exchange 2013 Powershell commands:
Get-MoveRequest -MoveStatus Queued
This will give me alle mailbox move requests that are currently queued but not yet processed.
Get-MoveRequest -MoveStatus InProcess
This will give you all mailbox move requests that are processed at the moment and not yet finished.
The arguments InProcess
and Queued
are predefined by the function. Is there any way to use InProcess
and Queued
in just one command? I know that I can run two commands and concenate the output, but I am curious if it is possible to use multiple of these predefined arguments at once. So the question is not Exchange specific, I want to know if Powershell can handle multiple predefined arguments as a commandlet parameter.
The Get-MoveRequest documentation does not state if or if not the MoveStatus parameter allows multiple values as argument.
- Is this possible?
- What is the correct syntax to test this, in case that the parameter allows mutli-value arguments?
0 Answers