Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the best way to deploy a VB.NET application?

Generally when I use ClickOnce when I build a VB.NET program but it has a few downsides. I've never really used anything else, so I'm not sure what my options are.

Downsides to ClickOnce:

  • Consists of multiple files - Seems easier to distribute one file than manageing a bunch of file and the downloader to download those files.
  • You have to build it again for CD installations (for when the end user dosn't have internet)
  • Program does not end up in Program Files - It ends up hidden away in some application catch folder, making it much harder to shortcut to.

Pros to ClickOnce:

  • It works. Magically. And it's built into VisualStudio 2008 express.
  • Makes it easy to upgrade the application.

Does Windows Installer do these things as well? I know it dosen't have any of the ClickOnce cons, but It would be nice to know if it also has the ClickOnce pros.

Update: I ended up using Wix 2 (Wix 3 was available but at the time I did the project, no one had a competent tutorial). It was nice because it supported the three things I (eventually) needed. An optional start-up-with-windows shortcut, a start-up-when-the-installer-is-done option, and three paragraphs of text that my boss thinks will keep uses from clicking the wrong option.

like image 796
Grant Avatar asked Aug 06 '08 15:08

Grant


2 Answers

Have you seen WiX yet?

http://wix.sourceforge.net/

It builds windows installers using an XML file and has additional libraries to use if you want to fancify your installers and the like. I'll admit the learning curve for me was medium-high in getting things started, but afterwards I was able to build a second installer without any hassles.

It will handle updates and other items if you so desire, and you can apply folder permissions and the like to the installers. It also gives you greater control on where exactly you want to install files and is compatible with all the standardized Windows folder conventions, so you can specify "PROGRAM_DATA" or something to that effect and the installer knows to put it in C:\Documents and Settings\All Users\Application Data or C:\ProgramData depending on if you're running XP or Vista.

The rumor is that Office 2007 and Visual Studio 2008 used WiX to create their installer, but I haven't been able to verify that anywhere. I do believe is is developed by some Microsoft folks on the inside.

like image 159
Dillie-O Avatar answered Oct 04 '22 22:10

Dillie-O


I agree with Joseph, my experience with ClickOnce is its great for the vast majority of projects especially in a corporate environment where it makes build, publish and deployment easy. Implementing the "forced upgrade" to ensure users have the latest version when running is so much easier in ClickOnce, and a main reason for my usage of it.

Issues with ClickOnce: In a corporate environment it has issues with proxy servers and the workarounds are less than ideal. I've had to deploy a few apps in those cases from UNC paths...but you can't do that all the time. Its "sandbox" is great, until you want to find the executable or create a desktop shortcut.

Have not deployed out of 2008 yet so not sure if those issues still exist.

like image 30
Robbo Avatar answered Oct 04 '22 23:10

Robbo