Vista Installation Error

Topics: Bugs, General Questions
Feb 16, 2007 at 7:12 PM
Edited Mar 6, 2007 at 7:25 PM
Applies To
  • 1.2.1 and earlier versions of DocProject
  • Windows Vista (presumably all editions, but the failure certainly can appear on Business and Ultimate)

Update: For 1.3.0 RC issues please see the remainder of this thread.

Note: Please read the last section of this document, "DocProject 1.3.0 Installation", as I've asked the community for some feedback. Thanks!

Symptoms
At some point near the end of the installation process, but before the Vistual Studio Content Installer runs (it will be obvious if you've gotten to this point), you receive the following message in an error dialog:

The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2869.

Clicking OK causes the installation to roll back.

Solution
It seems that DocProject isn’t the only software suffering from this type of installer problem on Windows Vista. I’ve seen many related newsgroup posts about failing installations on Vista. Some of their solutions follow, aggregated as one solution. I suggest that you try these steps to see if they work for you:

Note: In my testing this solution did NOT work for me on Vista Business, so I offer it only as something to try if you desperately need DocProject and cannot wait for the next release, 1.3.0. Hopefully, you'll have better luck with it than I.

  1. Make sure that Visual Studio is completely closed before attempting to install DocProject. This means closing Visual Studio and then opening Task Manager and watching for all instances of the devenv process to disappear from the list.
  2. Locate the Start > All Programs > Accessories > command Prompt shortcut, right-mouse click and select Run as administrator.
  3. You may have to accept the UAC dialog to continue, or enter an administrative user name and password.
  4. CD to the directory where you have downloaded the DaveSexton.DocProject.Installer.msi file. e.g., cd c:\Users\Dave\Desktop\ .
  5. Run the following command: msiexec /i DaveSexton.DocProject.Installer.msi to install DocProject

Cause
I’ve done some research and narrowed the problem down to two completely different issues. The first bug, which is the one causing the rollback, has to do with the custom installer actions failing. The second is a problem with the ErrorDialog dialog, which I analyzed in Orca and it appears to be setup correctly, so I have no idea where that problem is coming from.

The real error is not the ErrorDialog bug, though, but since that’s failing too we are presented with an error related to it, hiding the real issue that was supposed to be presented to us via the ErrorDialog itself.

If you dig through the Application log in the Event Viewer for errors, or the installation log if you create one using the command-line, you’ll see the true error. On mine, it’s a problem with the custom installer action “.install”. Since my custom installer doesn’t override the Install method (i.e., the installer only performs whatever the default actions are for the “install” command), I decided to remove the registration for that particular action and tried the installation again. But that didn’t fix the problem since the error I got instead was for the “.commit" action failing, which my software does require. If I remove the custom actions completely then the installation works, but obviously it’s incomplete and so is unacceptable. If I leave the commit action registered but remove all of my code, it still fails. Even more interesting than that, using Debugger.Break seems to do nothing, indicating to me that my code is never actually executed. This includes code in my installer's constructor - it's never executed.

Executing the custom actions using the InstallUtil via the command-line seems to work just fine.

DocProject 1.3.0 Installation
Since it's not my code causing this error (probably MS's InstallUtil shim that has the bug), there’s not much I can do about this issue except to make 2 separate installers or stop using the Visual Studio Content installer. If I make two installers, one would be for XP and one for Vista. The Vista installation would come with the .msi, custom actions removed, and a bootstrap that will execute the custom actions automatically after installing the .msi. Well, that’s my plan for now anyway. If the “.uninstall” action has the same problem, which I suspect that it might, then uninstallation will still be incomplete in 1.3.0, just like the pre-1.3.0 versions of DocProject.

I'm also considering performing the complete installation in the setup project, without using the Visual Studio Content installer. So what do all of you think? Do you prefer to see the Add-In and Templates being installed and have the option of choosing the ones you want or did you consider that to be more of an annoyance? Please reply to this thread with your comments and suggestions.

1.3.0 will be delayed a bit longer now while I try to work out the installation kinks. I'm sorry about any inconvenience this may cause. It’s too bad about all of this because I finally fixed the two outstanding issues for incomplete installation and not being able to choose the installation directory, and I was looking forward to a nice installation experience for DocProject on Vista. Hopefully this issue will be resolved by the next release of DocProject :)
Mar 6, 2007 at 4:35 PM
Any updates on this issue? I'm still having a problem installing on vista with 1.3.0 RC.

Thanks,
Clint
Mar 6, 2007 at 7:15 PM
Hi Clint,

The deployed 1.3.0 RC installed on my Vista box without a problem so I just assumed that the problem had been resolved.

Make sure that you install the Add-In using the Visual Studio Content Installer wizard when it appears. In other words, just make sure that every component has a check next to it before clicking Next.

If you're getting the 2869 error message then you can get at the real error by making a slight modification to the installer package using the Orca tool. Knowing the actual error on your system would be really helpful to me. Actually, I'll go ahead and add a Vista-special 1.3.0 RC package to the Release tab with the necessary modifications. (I just discovered this solution recently when trying to install 1.4.0 for testing). Please go ahead and try to install the updated version of 1.3.0 RC for Vista and let us know what error you get, if any. (FYI, I read on some MSDN blog that the 2869 ErrorDialog issue will be fixed in the VS 2005 update for Vista.)

- Sorry for any inconvenience, and thanks for the feedback.
Apr 6, 2007 at 10:03 PM
Edited Apr 6, 2007 at 10:04 PM

1.4.0 RC


There is only one installation package for the 1.4.0 RC release of DocProject. The package includes the fix for Vista installations so that any errors that occur will be displayed instead of the 2869 error message.

The Installer project in the source code has a post-build event that executes a batch file in the InstallPrep project, which patches the DaveSexton.DocProject.Installer.msi database automatically after it's built.

If anyone still has problems installing on Vista, please let me know.