[Fix For] Windows error 2502, 2503 - Unable to install or uninstall software
Windows error 2502, 2503 - Unable to install or uninstall software
So when attempting to install or uninstall a software, I was getting the error code 2502 and 2503, because the installation and uninstall of MySQL fails. There are different ways to workaround this issue as I have found online. Some work in some cases, some don't. You may try any of the below way and see which works in your case.
Method 1: Create a batch file to kill the Explorer and try executing the install/uninstallation
So when attempting to install or uninstall a software, I was getting the error code 2502 and 2503, because the installation and uninstall of MySQL fails. There are different ways to workaround this issue as I have found online. Some work in some cases, some don't. You may try any of the below way and see which works in your case.
Method 1: Create a batch file to kill the Explorer and try executing the install/uninstallation
- Create a .bat file - right-click anywhere in windows explorer and do "New Text Document"
- Paste this code in it
msiexec /unreg
msiexec /regserver
TASKKILL /IM explorer.exe /F
explorer.exe - Rename the file to "anyname.bat"
- Run the batch file as administrator
- Retry the installation/uninstallation
- Right-click on the taskbar and click on "Task Manager"
- Find "Windows Explorer" in the list
- Right-click on "Windows Explorer" and click "End Task"
- Try the install/uninstall again
Method 3: Add the current user to the Windows Temp folder and grant full permissions
- Open Windows Explorer and navigate to C:\Windows\
- Find "Temp" folder
- Right-click on "Temp" folder and select "Properties"
- Click on "Security" tab
- Under "Group or User name", click "Edit"
- Click "Add"
- At "Enter the object name to select", enter the "current-user" and click "check name"
- Click OK
- Under "Group or User name",find the "current user" just added and click to select
- Allow "Full Control' to the "current user" just added
- Click OK
- Click Apply
- Click OK
[Comment: This worked in my case. I am now able to install and uninstall programs without any errors.]
Method 4 [Workaround for uninstallation] : If the problem is with uninstallation, find the uninstaller file and uninstall
This work around always works if there are issues with uninstallation of software on Windows computers.
Find the .msi file that the program uses for uninstallation
- Press Windows + R key to open the "Run" command
- Type in C:\Windows\Installer and press Enter.
- Windows Explorer window opens the directory C:\Windows\Installer
- Right click in a blank space and click View -> Details.
- Right click anywhere on the column bar and click More…
- In the list of column choices, select "Subject"
- Click the Subject column to sort the program names in alphabetical order. Find the program name to uninstall. (In this example I am looking for Microsoft SQL Server 2008 R2 Native client)
- Open a command prompt as an administrator
- Type "cd C:\Windows\Installer" and hit enter
- The command prompt will now be at "C:\Windows\Installer>" directory
- Enter the name of the MSI file we found in the previous step and hit enter. Example: 19e139c6.msi
The uninstaller will now run and should uninstall successfully.
As you can see in the screenshot below, when attempting to uninstall the Microsoft SQL Server 2008 R2 Native Client from the Control Panel, it was not successful. But following the process as described above using the MSI file, the uninstaller successfully runs and the program was uninstalled successfully.
No comments