I am creating an MSI package using Visual Studio and I have added in the SQL Express set up, it all works fine, except I would like to automatically open the SQL Express when the application has finished installed.
I did a bit of investigating and saw an option in Visual Studio in the properties window for the Setup named PostBuildEvent. Can I add a custom macro here to boot the SQL Express installer? If so, how would I go about doing this? And if not, does anyone have any suggestions on how I could make this work?
Any help would be GREATLY appreciated, thank you!
The post build event runs on your machine immediately after the build of the MSI file completes. It will run code immediately after Visual Studio is completes building the MSI. It will not run when an end-user installs the application.
To have the installer run code after the end-user installs the application use a Custom Action.
Related
I've been given a Visual Studio solution someone else made. It has an installer project using Installshield LE. The installer builds fine but it makes an exe and I'm supposed to make an msi. I know the guy who wrote the project would generate msi files but I just don't see any options to do it. Is this doable with LE?
Go to step 6 and drill down to the Single Image release type. Set Compression on the build tab to yes and set setup launcher on the setup.exe tab to no. Build this release.
Thanks for the help, guys. These tips sorted my issue.
After so many 1990s-looking releases, its amazing that InstallShield finally went to the trouble to make their Visual Studio integration so friendly... yet hid this vital option away.
I'm adding a screenshot, to help other users.
I've solved it by using the following
By using SingleImage as the build type
Under - Setup.exe tab (Build | Setup.exe | Signing)
Select Setup Launcher = No.
The build from InstallShield will come out as a .MSI file under
(\RELEASE_PROJECT\Express\SingleImage\DiskImages\DISK1)
I have created a windows based application in C# using visual studio 2008 which basically scans for the registry and then fixes the resulting errors. Now using the msi installer i have made a setup and it works fine. However i have met with a new requirement.
Usually after providing the setup to the user/client has to install the setup and when installed, in the installed folder there are lots of .dlls that i had used to create the project. But my requirememt is to create a single standalone .exe using which i wouldnt have to provide my users with the setup file. All i need to do is that using this single .exe file my whole project should execute and perform the same process of scanning and fixing the registry.
I also tried "ClickOnce Deployment in .NET Framework 2.0" and got the error "ClickOnce does not support the request execution level 'requireAdministrator'". and also have gone through the link
"ClickOnce does not support the request execution level 'requireAdministrator.'"
But still i feel that i would be comfortable if i can get a single standalone exe which can execute my windows forms application.
Is there any way to do it?
Any hint with this thing will be really helpful to me.
Thanks in advance
~Viknesh
I have a bunch of programs set up as prerequisites in the VS bootstrapper. Recently, everytime I build on my machine and try to run setup.exe, I get an error ".....msi has either changed or been corrupted since the package was originally published". I know this isn't a problem with the setup or the msi files because I done the exact same thing on another development machine and copied the output to my machine and it's worked. I figure it must be something within the visual studio - bootstrapper connection. Anybody have any ideas?
Have you tried checking the log file ActivityLog.xml. It's under AppData\Roaming\Microsoft\VisualStudio\10.0
You need to run Visual Studio this way "Devenv /log"
i want to make a uninstall option in my C# program?
can u help for this?
and provide some code also
If you deploy your application via a Visual Studio Setup and Deployment Project, an uninstaller will come standard with the installation. It will be available in the Add/Remove Programs of the control panel.
You can create an installation project which will automatically add support for uninstallation. Under Other Project Types you have Setup and Deployment. There is InstallShield LE and Visual Studio Installer. If you choose Setup Project under Visual Studio Installer project, you will have uninstall as part of the built project.
see this video
http://www.youtube.com/watch?v=Z-xFLltALg0
If you want the executable to remove itself. aka self-destruct. Check out this blog http://blog.pedroliska.com/2010/05/20/c-self-destruct-windows-app/
A colleague has written a Windows Application and left me to do the installers. I have created the installer project through Visual Studio and added the primary output of the service project to the new project.
When I run the installer it creates the correct folders and copies the dlls, exe and config file in, but it doesn't do the actual install of the service.
The service isn't listed in the Services window, and if I double click on the exe I'm told I need to run installutil to install the service.
How do I make the installer do this bit for me? I found this article:
http://www.codeproject.com/KB/install/InstallService.aspx
but that seems overly complex for what I would expect to be pretty basic.
I used this article:
How to create a Setup project for a Windows Service in Visual Basic .NET or in Visual Basic 2005
Felt pretty dumb that I couldn't figure it all out until I went through all of the steps in this article. It's not a trivial exercise by any means.
For those who are looking for updated instructions for Visual Studio 2010 (instructions in answer are for VS 2005) check the following link:
Walkthrough: Creating a Windows Service Application in the Component Designer (note that "other versions" [VS 2005, VS2008] are available from the same link)
I had this issue in my case the problem was I neglected to add the custom actions for the installer project. To find these right click project->"view"->"custom actions" under there it needs the primary output added to the folders.