Marcin Kawalerowicz runs a consultancy in Silesia, Poland. Craig Berntson has been Microsoft MVP since 1996. They are the authors of Continuous Integration with .NET.
ClickOnce is a Microsoft technology that lets you deploy a Windows Form or Windows Presentation Foundation (WPF) application via a Web page. With ClickOnce, users get to decide whether to install an application upgrade.
With ClickOnce, a "smart client" application is installed in a sandbox on the client machine with fewer rights than it would otherwise get. For example, it has no access to local files, and it's installed in a user's private folder, not in the Program Files.
For example, to make the Windows Calculator available via ClickOnce, go to the CiDotNet.WinCalc project properties and switch to the Publish tab (Figure 1). You'll need a Web server like Microsoft's Internet Information Service (IIS) to host your published apps.
Figure 1 shows a publishing target laying somewhere in the local network. In our test setup, IIS is installed on the ci1 server, sees the WinCalc folder, and is able to immediately host the WinCalc application. If you have Front Page Extensions installed on the remote IIS server you will be able to publish onto it right away.
To make the published version look nice you should define the deployment web page. Click on the Options… button. Fill in the Description then select Deployment from the listbox (Figure 2).
It's time for a test publication. Press the Publish Now button or use the publishing wizard. Then, launch Internet Explorer and open the remote location. Be advised that Firefox and other browsers do not support ClickOnce without special plugins.
Now, if you click Install, WinCalc will be installed on your computer. The whole process works like a charm from Visual Studio. With a command line (and eventually Continuous IntegrationI), it is not so easy, as you will see next.



