Select-AzureSubscription
[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]
Select-AzureSubscription
Selects or clears a Windows Azure subscription to be used as the current subscription.
Parameter Set: Set
Select-AzureSubscription [-SubscriptionName] <String> [[-SubscriptionDataFile] <String> ] [[-PassThru]] [ <CommonParameters>]
Parameter Set: Clear
Select-AzureSubscription [-Clear] [[-SubscriptionDataFile] <String> ] [[-PassThru]] [ <CommonParameters>]
This topic describes the cmdlet in the .6.19 version of the Windows Azure PowerShell module. To find out the version of the module you're using, from the Windows Azure PowerShell console, type (get-module azure).version.
The Select-AzureSubscription cmdlet selects or clears the subscription to be designated as the current subscription. A current subscription is the one whose settings are available for use by other Windows Azure PowerShell cmdlets.
-Clear
Specify to clear the current selection. When no subscription is current, the necessary information must be explicitly specified in the command line when running any Windows Azure PowerShell cmdlet.
Aliases |
none |
Required? |
true |
Position? |
2 |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-PassThru
Aliases |
none |
Required? |
false |
Position? |
4 |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-SubscriptionDataFile<String>
Specifies the path and file name of the subscription data file. This parameter is optional. If it is not provided, the subscription data is selected from a default file in the user's profile.
Aliases |
none |
Required? |
false |
Position? |
3 |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
-SubscriptionName<String>
Specifies the name of the subscription that the Windows Azure PowerShell cmdlets will use to read default values. Use the Set-AzureSubscription and Import-AzurePublishDataFile cmdlets to store settings for one or more subscriptions.
Aliases |
none |
Required? |
true |
Position? |
1 |
Default Value |
none |
Accept Pipeline Input? |
True (ByPropertyName) |
Accept Wildcard Characters? |
false |
<CommonParameters>
This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).
Inputs
The input type is the type of the objects that you can pipe to the cmdlet.
Outputs
The output type is the type of the objects that the cmdlet emits.
Example 1
This command selects "MySubscription" as the current subscription.
C:\PS> Select-AzureSubscription "MySubscription"
Example 2
This command selects "MySubscription" as the current subscription and retrieves its settings from the specified subscription data file.
C:\PS> Select-AzureSubscription "MySubscription" -SubscriptionDataFile "C:\subs\MySubscriptions.xml"
Example 3
This command clears the current subscription selection.
C:\PS> Select-AzureSubscription -Clear