Don't have ExpressRoute or a VPN connection to Azure?  Are you logging into the Azure Portal every time you need to connect to a VM?  Ever wondered how to grab all those .RDP connections for VMs in Azure?  Well now you can.

Export Azure VM .RDP files to a local directory for a given service.  The following script will export all VM .RDP connections to a local folder created by the user.
Install Azure PowerShell by visiting: http://azure.microsoft.com/en-us/documentation/articles/install-configure-powershell/

PowerShell
Edit|Remove
<# 
.SYNOPSIS  
    Export VM .RDP files for a given Azure service. 
 
.DESCRIPTION 
    The following script will export all VM .RDP connections to c:\AzureRDP folder.  The folder must be created by hand before the script is run. 
 
.PARAMETER ServiceName 
    Cloud Service the Azure VM is running under. 
 
.PARAMETER SubscriptionName 
    Name of the Azure subscription being selected. 
 
#> 
 
 
Param 
 
( 
 
[parameter(Mandatory=$true)] 
 
[String] 
 
$ServiceName, 
 
[parameter(Mandatory=$true)] 
 
[String] 
 
$SubscriptionName 
 
 
) 
 
Add-AzureAccount 
 
select-azuresubscription "$SubscriptionName" 
 
Get-AzureVM $ServiceName | foreach {  
    $rdpexportfile = 'c:\AzureRDP\' + $_.Name + '.rdp' 
    Get-AzureRemoteDesktopFile -ServiceName $ServiceName -Name $_.Name -LocalPath $rdpexportfile 
}