Whenever I try to uninstall my WIX installation via Add/Remove Programs or the uninstall shortcut I put down with the installation, I keep getting the following error:
a network error occurred while attempting to read from the file c:\windows\installer\MyProduct.msi
But if I use the original installer and select uninstall then it is fine. Why is this happening as obviously you can't expect customers to hang onto the original installer if they need to uninstall my product!
After some testing it seems that if I install then uninstall straight away then it is fine, but if I log off or restart the computer then I get the error.
Update: Once an install is finished I run a custom action to delete a folder which temporarily holds some database files used during the install. After digging around it seems that the uninstall is trying to access these files, why would it be doing that, it has nothing to do with uninstallation?
"C:\Windows\Installer" folder is the Windows Installer cache. It's used to store MSI packages for installed products. These packages are used by Windows Installer when performing a repair or modify operation on the product.
In your case the uninstall process needs some files which are missing. The MSI in Windows Installer cache is not complete (it's just a stripped down version), so you are prompted for the original package.
Usually this behavior is triggered by custom actions which try to use files that are not available during uninstall. Try creating an uninstall log to see what triggers this.
Related
I'm trying to install the update 4 of Apache Cordova (VS2015). But it instantly comes back with the following error message:
The selected Visual Studio item 'Visual Studio Tools For Apache Cordova Update 4' failed to install. Check the %TEMP% directory for VS install logs.
When I go to that directory, I don't see any log related to this install. Even when sorting everything on date descending, there is no log related to this install.
This update can't be found on the Microsoft site either as a separate download or something.
Anyone else bumped into this error?
Make sure you're looking in the correct %TEMP% directory for VS install logs, since each user account on your computer will have a separate user account. Try checking that the %TEMP% folder you're in is the right one for the user account associated with VS2015 on your local machine. It should look something like "Microsoft_Visual_Studio_Tools_for_Apache_Cordova_20151106165019_001_ApacheCordovaTools.msi".
Once you're in the right folder, try looking in %TEMP% again for the log. I'd recommend sorting the folder by date added and looking for a file with the term "Cordova" in it.
Also, make sure you're connected to the internet when you install.
I have crated Msi Installer using visual studio setup and Install project.My set up is working fine on some machine but on it works fine only when I am installing that set up using command prompt with admin privilege else installer completed but I am not able to see any file in programme file. So what can be issue?
I think Visual Studio generated MSIs behave badly when they require admin privilege but you don't use it. I think you'll find they install all the files to C:\ somewhere. The essential question is not if the files are there, oddly enough, but whether you see an entry in Add/Remove Programs (Programs&Features) because that means the install succeeded, because you don't mention an error the install rolling back. I think you are saying that there is an entry there.
Did you mark the install as for Everyone or Just me? That seems to make a difference, and I suspect you have a Just me install, which still means that you need admin privilege if you install to restricted locations. The Just me install does not mean a limited user can write to restricted parts of the system.
I have a trouble getting a ClickOnce, C#, Visual Studio application to install. I get the following error (retyped):
Setup has detected that the file
C:\...\Reportviewer.exe
has changed since it was initially published.
Click OK to retry the download or Cancel to exit Setup.
I deleted the previously existing Reportviewer, but the error persists. I'm doing this install via VPN (if it matters). What does this actually mean, and what can I do about it?
In the end, I took the ReportViewer prerequisite (and all the other prerequisites, too) out of the published version. We install ReportViewer from here:
http://www.microsoft.com/en-us/download/details.aspx?id=4016
You say that you've deleted the previously existing Reportviewer but there's a strong likelihood that you have some temporary files that are still being referenced during setup.
Try cleaning out any files under C:\Users[Username]\AppData\Local[AppFolderName] or C:\Users[Username]\AppData\Roaming[AppFolderName] manually. If that doesn't work, try using the cleanmgr.exe utility to do a cleanup and then try reinstall.
The WIX installer I'm writing needs to install several operating system files in system folder. The program I'm writing this installer for is an old program... probably 10 years. I don't want it to replace any preexisting OS files on the user's machine. To resolve this, I figured I could use "NeverOverwrite="yes"
My problem is during the uninstall. I want the installer to ONLY uninstall the files it added. I don't want it to uninstall any pre-exisitng OS files the user already had.
Thank you
The installer should not delete files that it did not install (as Natalie commented), unless you specifically tell it to.
That said, when I need to install files directly to the system folder, I mark them as permanent so they never get uninstalled. Usually it's a Mircrosoft control or some OS file for which I don't have a separate redistributable installer, but if I had I wouldn't uninstall anyway.
I have a service and a VS installer/setup project.
The installer installs/registers and uninstalls/unregisters the windows service fine.
In order to install without uninstalling I have RemovePreviousVersions set to True and I increment the version on the setup project properties and it prompts to also change the ProjectCode. All of this allows me to run the installer over the top of the previous one.
However during the install when it tries to register the service it complains that the service is already registered "Error 1001. The specified service already exists"
Should I test for this in my installer and not register the service again? This feels wrong because I expected it to uninstall the older version before installing the new version.
What bugs me is that when I right click the project and select "Install" from inside VS, it does all of this exactly correct without even having to increment versions etc.
Try setting a condition in custom action - install in your setup project:
Not (Installed OR PREVIOUSVERSIONSINSTALLED)
You already have installed service in your system, you just need to update binary files.