Locations
Get-XpLocation
Syntax
Get-XpLocations [[-LocationNames] <String[]>] [-Timeout <int>]
Description
The Get-XpLocations
command delivers location objects.
Without parameters, Get-XpLocations
delivers all of the locations of the XPhone Connect Server but one or more location names can also be provided which are then sought on the XPhone Connect Server.
By default, the command only provides the name of the location and its description. Using the Select-Object
command however, all available features of the locations can be provided (see examples).
Parameter
-LocationNames <String[]>
This optional parameter specifies one or more location names. Locations are then searched for on the XPhone Connect server using these names.
Several names are provided separated by a comma.
Hint
A distinction must be made between upper- and lower-case letters!
The wildcard symbol
*
can be used at the beginning or end of the string to be searched for. Accordingly,-LocationNames Main*
, for example supplies the locations with the names“Main location”
and “Main secondary location”.
If names include special characters such as blanks or commas, they must be in inverted commas:
-XpLocations -LocationNames "Frankfurt am Main","Haupt-Standort"
-Timeout <int>
Timeout in minutes.
Input
This command does not support input via the pipeline and is usually at the beginning of a command chain.
Output
The Get-XpLocations
command does not deliver any CFGBranch-type objects.
CFGBranch:
Property |
Supported values |
---|---|
Description |
String |
FunctionAnnouncement
|
BranchActive
BranchInactive
|
FunctionClient
|
BranchActive
BranchInactive
|
FunctionCollaboration
|
BranchActive
BranchInactive
|
FunctionContactList
|
BranchActive
BranchInactive
|
FunctionFax
|
BranchActive
BranchInactive
|
FunctionAnnouFunctionInstantMessagingncement
|
BranchActive
BranchInactive
|
FunctionLanguage
|
BranchActive
BranchInactive
|
FunctionMailbox
|
BranchActive
BranchInactive
|
FunctionMobileControl
|
BranchActive
BranchInactive
|
FunctionPasswordComplexity
|
BranchActive
BranchInactive
|
FunctionPresence
|
BranchActive
BranchInactive
|
FunctionSms
|
BranchActive
BranchInactive
|
FunctionTelephony
|
BranchActive
BranchInactive
|
FunctionVoicemail
|
BranchActive
BranchInactive
|
Id |
- |
Name |
String |
ExtensionData |
- |
UtcOffset |
- |
Example
Show all locations:
>Get-XpLocations
Show all locations starting with “Ha”:
>Get-XpLocations Ha*
Show the Main location and Secondary location locations:
>Get-XpLocations Hauptstandort,Nebenstelle
Show the Main location 2 (contains blanks!):
>Get-XpLocations "Hauptstandort 2"
Set-XpLocations
Syntax
Set-XpLocations [-Objects] <CFGBranch[]>
Description
Set-XpLocations
saves the transferred CFGBranch objects from Get-XpLocations
in the XPhone Connect Server.
All changes made to the object are immediately transferred to the XPhone Connect Server without query where they are saved.
Warning
The search basis saved is no longer valid and is deleted. Please select a new search basis.
Parameter
-Objects <CFGBranch[]>
The list of CFGBranch objects originates from
Get-XpLocations
, is changed and then redirected via the pipeline toSet-XpLocations
(see input).This parameter is mandatory as otherwise it is impossible to save any locations in the XPhone Connect Server.
-Timeout <int>
Timeout in minutes.
Input
The input type is the type of object which can be transferred to Set-XpLocations
via pipelining:
CFGBranch
Output
The Set-XpLocations
command does not deliver any objects.
Example
The general procedure for changing location data is as follows:
Get desired locations
>Get-XpLocations
Change features
>foreach{$_.Eigenschaft = „Wert“;$_}
Save location changes in XPhone Connect Server
>Set-XpLocations
It is important to check the data again after step 2 (Change) before saving them in the XPhone Connect Server. The 3rd step (Save) is initially dispensed with. All objects are then output in their new status on the PowerShell console but not saved.
Example Set-XpLocations
Deactivating faxes at all locations:
>Get-XpLocations | foreach{$_.FunctionFax = "BranchInactive";$_} | Set-XpLocations
Hint
In order to check the changes before saving in this example, step 3 (
Set-XpLocations
) is left out. This results in the following command:>Get-XpLocations | foreach{$_.FunctionFax = "BranchInactive";$_}
Analog to 1: Activating faxes at all locations:
>Get-XpLocations | foreach{$_.FunctionFax = "BranchActive";$_} | Set-XpLocations
Deactivating faxes and voicemails at the Main location and Secondary location:
>Get-XpLocations „Hauptstandort“,“Nebenstelle“ | foreach{$_.FunctionFax = „BranchInactive“; $_.FunctionVoiceMail = „BranchInactive“;$_} | Set-XpLocations
Have you found an mistake on this page?
Please send us a hint about this error by mail to doku@c4b.de. Thank you very much!