Vb.net – ClickOnce Online-Only Application as a TS RemoteApp

clickonceremoteappvb.net

I've attempted just about everything to get our ClickOnce VB.NET app to run under Terminal Services as a RemoteApp. I have a batch file that runs the .application file for the app.

This works fine via RDP desktop session on the terminal server. As a TS RemoteApp, however, well… not so much.

I get a quick flash of command prompt (the batch file) on the client system and then… nothing…

Same goes for having it point to the .application file directly (without using a batch file) or even copying the publication locally and having it point to that.

I found a technet.microsoft.com discussion about a similar issue, but there's no resolution to it listed.

For anyone who has run into this before and got it working, what did you have to do?

We currently use RemoteApp's for everything else on that server, so I'm hoping to stick with that if possible.

The current workaround is to build and run an MSI-based installer for the app on our terminal server whenever we publish via OneClick out to the network, but this can be quite a pain at times and is easy to forget to do.

Since the app works fine via Terminal Services when run in full desktop mode but not during RemoteApp, I don't think it's anything specific to Terminal Server permissions so much as ClickOnce requiring something that isn't available when running as a RemoteApp.

Best Solution

The Key to getting it to work is to use Windows Explorer "C:\windows\explorer.exe". This process is the base process when you login to a full session.

If you setup the RemoteApp to use Windows Explorer and the command line argument of the path to the .application file for the ClickOnce application then it will work when launched as a remote application. Windows Explorer will flash for a second when it starts, but it will disappear then the ClickOnce application will launch.

Related Question