Publishing question

johmolan

Well-known member
Joined
Oct 11, 2008
Messages
129
Programming Experience
Beginner
I have a windows application

Is it possible to publish this in a way that it does not have to be installed,
Like if I just double-click the .exe file then the form appears and run instantly?
 
There is no publishing then. You build the project and that's it. You can just copy the EXE from the output folder, along with any other dependencies (config file, DLLs, data files), to the target system and run it. You will, of course, require the .NET Framework to be installed, along with any other required components, e.g. SQL Server Express.
 
There is no publishing then. You build the project and that's it. You can just copy the EXE from the output folder, along with any other dependencies (config file, DLLs, data files), to the target system and run it. You will, of course, require the .NET Framework to be installed, along with any other required components, e.g. SQL Server Express.

I heard that there is a bootstrap available for sqlserver express so you would not need to install the sql extra? Do you know about it and if yes, where can a person download it?
 
An installer boostrapper is just a means for an install package to detect and initiate install process for external packages. In VS today bootstrappers are included and available by default for such prerequisites as the Windows Installer, the .Net Frameworks, Powerpacks and Sql Server editions.
 
Further to what JohnH posted, if you're using ClickOnce then you can open the Publish page of the project properties and click the Prerequisites button to view the available packages. Some will be checked by default, including the appropriate Framework and Windows Installer, as well as SQL Server Express and the VB PowerPacks if you have used them in your project. If you're using Windows Installer, you can open the properties for your Setup project and get access to the same Prerequisites dialogue. Note that you can also create your own packages for other components your app may depend on.

Of course, bootstrapping installers requires that you be using an installer for your app, which this thread was specifically about NOT doing.
 
If I choose the option, to download the packages from the same location as my application, under Prerequisites
will VS include these packages when I publish my application?
 
If I choose the option, to download the packages from the same location as my application, under Prerequisites
will VS include these packages when I publish my application?

I theory, yes, although at least VS 2008 doesn't actually install some of the packages so you need to do a little bit of messing around in that case. Just give it a try and, if you get an error message, search for that on the web and you'll find instructions on the manual steps you need to perform.
 
Back
Top