How to silently deploy RemoteApp Programs to the Start Menu
RemoteApp in Windows Server 2008 R2 Remote Desktop Services finally allows you to do what some 3rd party solutions have been doing for years – delivering published applications directly to the user’s Start Menu. The bad news is that this feature requires Windows 7 and Windows Server 2008 R2, but your migrations plans are well underway right?
Creating the connection on the client computer is easy – setup a new connection via RemoteApp and Desktop Connections in Control Panel or ask users to double click on a connection file that you’ve created on the RD Connection Broker.
The wizard is simple enough, just click the Next and Finish buttons when prompted, the wizard will do the rest:
But what if you want to deliver the connection silently? Fortunately that’s easy, but it’s one of those things that just isn’t documented. Here’s how to do it.
Creating the RemoteApp and Desktop Connections Configuration File
There are some excellent resources for setting up RemoteApp sources, Remote Desktop Web Access and publishing applications, so there’s no need to cover those again. If you haven’t already configured the Remote Desktop Session Host servers, Remote Desktop Virtualization Host servers (for publishing virtual desktops) and the Remote Desktop Connection Broker see these step-by-step guides first:
- Deploying Remote Desktop Web Access with Remote Desktop Connection Broker Step-by-Step Guide
- Deploying Personal Virtual Desktops by Using Remote Desktop Web Access Step-by-Step Guide
- Deploying Virtual Desktop Pools by Using Remote Desktop Web Access Step-by-Step Guide
- Deploying RemoteApp Programs to the Start Menu by Using RemoteApp and Desktop Connection Step-by-Step Guide
Now that you’ve configured your RemoteApp and Desktop sources and RD Web Access and confirmed that you can manually add a RemoteApp and Desktop Connection source to your client machine, you’ll need to create the RemoteApp and Desktop Connections Configuration File.
Open the Remote Desktop Connection Manager tool on the Remote Desktop Connection Broker and choose Create Configuration File. Enter the URL to the RAD Connection feed, in my case this is https://home.stealthpuppy.com/RDWeb/Feed/webfeed.aspx
Click the Save button and save the configuration file to a location that you can also access from the client machine. The configuration file is just simple XML, so open it in Notepad to view the contents.
Adding the RemoteApp and Desktop Connection
Adding the connection is simple, but you will need to do this in the users’ context, so you’ll have to use a logon script or similar to run the command. The machine on which the command is run must also be connected to the network (it will fail silently if a connection can’t be made) and be able to make a connection to the Remote Desktop Connection Broker. To add the workspace silently run this command:
rundll32.exe tsworkspace,WorkspaceSilentSetup <path>\connection-file.wcx
That’s it. If the connection already exists and the command is run again, it will fail silently.
Advanced Configuration
A PowerShell script is available from Microsoft that can check whether the connection already exists before running the setup command and will log an event if the setup fails. The script can be found here: Configure RemoteApp and Desktop Connection on Windows 7 Clients