views:

161

answers:

5

Hi all,

Bit of a strange question, but how do ClickOnce deployments work from a web site? I seem to be having some problems with this. Basically, the setup file will download when you click the "install" button, but then some files are missing.

Do you need to be on a Microsoft server to run ClickOnce deployments? I usually do deployments over a local server with UNC, and as this is the first time I've done one online I'm struggling a bit.

Any newbie tutorials you can point me to would be great, and if I do need a special host for it, could you please recommend some?

Thanks for all the answers everyone :)

+2  A: 

Are you going to the setup.exe file or the .application file?

Deployment has to be pointed to the .application file. The ClickOnce file will then be launched directly there, no explicit "Save as" download. Once the manifest is loaded, the application will download what it needs and off it runs.

Kyle Rozendo
Given that the current browser and OS supports ClickOnce.
Peter Lillevold
+1  A: 

The first thing you need to do is determine if you want the user installing your app to run locally or launching it from the web only.

Second make sure you are using Internet Explorer to launch your application. The .application is registered in IE, but not other browsers.

I'd recommend server only. (At least to start) You don't have to worry about incremental updates. The user will get the correct version of your program every time.

There is nothing special going on with the server. It's all in the browser/.application.

Brad Bruce
Firefox can be used as well as long as .NET Framework Assistant Add-On is installed.
kzen
+1  A: 

It works from any file server, for example here is a ClickOnce deployment from an SVN server (i.e. I'm checking in the ClickOnce files after each publish): http://o2platform.googlecode.com/svn/O2_ClickOnce_Installers/O2_XRules_Database

Can you provide more details on what settings you have on the Publish tab of your project?

Regarding missing files, yes it can be a pain since ClickOnce doesn't auto add all dependent files from sub projects (I have found in the past that you need to include the extra (non dlls) files you need in the project you are deploying via ClickOnce)

Dinis Cruz
+1  A: 

No special hosting requirements are needed. You just need to make sure all the files required by the published clickonce app are deployed.

Take a look here : http://msdn.microsoft.com/en-us/library/31kztyey%28VS.80%29.aspx

Bruce Adams
+1  A: 

You can deploy to a webserver using either FTP or HTTP. You need to have the following MIME types set up in order to host the deployment:

.application --> application/x-ms-application
.manifest --> application/x-ms-manifest
.deploy --> application/octet stream

If you are deploying .Net 3.5 as a prerequisite, you need these as well:

.msp --> application/microsoftpatch
.msu --> application/microsoftupdate

If you have vsto apps, you need this one:

.vsto --> application/x-ms-vsto

Check out the Application Files dialog in the Publish tab to see what files are included. You can try running the exe file from your \bin\release folder, but if it's using something in the Global Assembly Cache (GAC), it will work and not tell you you're missing it.

Here are some other helpful links:

ClickOnce Overview
http://msdn2.microsoft.com/en-us/library/142dbbz4(VS.80).aspx

HowTo publish a clickonce app
http://msdn2.microsoft.com/en-us/library/31kztyey(VS.80).aspx

RobinDotNet
Visit my ClickOnce blog!

RobinDotNet