cancel
Showing results for 
Search instead for 
Did you mean: 
rogerbrown
New member
4 2 0 0
Message 1 of 11
2,376
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

HP Envy 4500 all in one
Microsoft Windows 10 (64-bit)

I have tried multiple times to uninstall the software for the printer and keep getting this message. "driverpackageuninstall returned error 5 for package" I have a HP Envy 4500.  How do I uninstall the software so I can install the updated software? I have gone to uninstall and tried to remove it with no results. I have gone to APPS and removed it. I have gone to printers and devices trying to remove it. Any help would be appreciated

10 REPLIES 10
Level 15
Level 15
23,815 23,596 2,044 7,474
Message 2 of 11
2,348
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

@rogerbrown 

 

If the software to which you refer is the Full Feature Software, the following should work:

 

If printer software will not uninstall, appears to be removed and then shows up again, or is otherwise not “going away” when you tell it to do so, try an Uninstaller program.

Microsoft:  Fix problems that block programs from being installed or removed

 

And, if it does not do it...

@ShlomiL likely has the in-directory instructions to sneak up on the software and force it off the system. 

Words of wisdom?

 

Once the software appears to be uninstalled, check some of the other spots where printer software hides - and remove where needed...

 

Trying to remove an "App"?  These are found in Settings > Apps > Apps and Features

 

 

** Uninstall - Printer Software – Lurking in the Device Manager **

 

Check / Verify:  If the printer is still lurking in the Device Manager, remove it.

Control Panel > icon view > Device Manager

Expand category Printers

If any unwanted printer name or “Unknown Device” is listed,

Right-Click on the printer / device > Uninstall

 

Expand category Imaging Devices

If any unwanted printer name or “Unknown Device” is listed,

Right-Click on the printer / device > Uninstall

 

If any devices are removed, Restart the computer and log in

 

 

** Uninstall - Printer Drivers – Lurking in Devices and Printers **

 

Check / Verify:  If the printer drivers are still lurking in Devices and Printers, remove driver(s) related to the printer.

Control Panel > icon view > Devices and Printers

Left-Click on any unwanted Printer found in the Printers list

Clicking on a printer, displays options along the ribbon (near the top of the Devices and Printers window)

Click Print Server Properties > tab Drivers

Click on Driver(s) in list, select Remove > OK to exit menu

Back in Devices and Printers > Right-Click on the printer > Remove Device

If any devices are removed, Restart the computer and log in

 

 

** Uninstall - Printer Software – Lurking in the User Account **

 

Check / Verify:  Printer related files and folders are stored in the User AppData hierarchy.  If you have had trouble getting the printer to work, complete this step to delete printer files from the Temp folder and the Local\HP folder

 

Clear Temp Folder in AppData

 

Method One

Open File Explorer > Navigate to C:\Users\YourAccount\AppData\Local\Temp

OR

Method Two

Windows key + X + R (Run command) > type %temp%

 

Delete the files in the Temp folder (It is expected that some files cannot be deleted, ignore these)

Restart the computer and log in

 

Clear HP Printer mention in AppData\Local\HP

 

Open File Explorer > Navigate to C:\Users\YourAccount\AppData\Local\HP

Remove / Delete any folder named for the printer you wish to remove

 

 

After all that is done, Restart the computer and log in.

Download-Save-Install the software.

 

 

Reference and Resources – Places to find help and learn how to use your Printer

Clarification of terms and "what the printer can do" (Specifications)

Printer Homepage – “Things that are your printer”

NOTE:  Content depends on device type and Operating System

HP Drivers / Software / Firmware Updates, How-to Videos, Bulletins/Notices, Lots of How-to Documents, Troubleshooting, Access to the Print and Scan Doctor (Windows), User Guides, Product Information (Specifications), more

When the website support page opens, Select (as available) a Category > Topic > Subtopic

HP ENVY 4500 e-All-in-One Printer series

 

Thank you for participating in the HP Community Forum.

We are a world community of HP enthusiasts dedicated to supporting HP technology.

 

Kind Regards,
Dragon-Fur
Level 16
Level 16
26,394 26,118 4,659 10,260
Message 3 of 11
1,923
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.


@ShlomiL likely has the in-directory instructions to sneak up on the software and force it off the system. 

Words of wisdom?


Ohh well @Dragon-Fur, it's like a Cat and Mouse fight with any Windows 10 update, but we will eventually win! 😏

 

I do have something in mind but it is quite too complex, will share some steps to resolve it much easier when will be back at my office tomorrow, have it saved there, after some research in the last days...

 

Cheers,

Shlomi

2019_MeetupAward_Signature_FINAL(1).png
Say thanks by clicking the Kudos thumb up in the post.
If my post resolve your problem please mark it as an Accepted Solution 🙂
Level 16
Level 16
26,394 26,118 4,659 10,260
Message 4 of 11
1,830
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

Please try the following steps and let me know the results @rogerbrown.

 

Before following any further, please make sure that the HP printer is the only HP device you have, any HP Device will be affected.

 

If you have multiple HP printers or an HP Computer, please stop at this point and let me know what exact HP products your have and DO NOT follow any further steps in this post!

 

  1. From the search bar type CMD, right-click on Command Prompt and select Run as Administrator.
  2. Copy the following command, then right-click the Command Prompt dialog and select Paste, then press Enter:
    Spoiler
    icacls "%windir%\System32\DriverStore\FileRepository" /grant %username%:(OI)(CI)F /T
    Note: this will provide your user full permissions to the FileRepository system folder
  3. Copy the following command, then right-click the Command Prompt dialog and select Paste, then press Enter:
    Spoiler
    for /d %G in ("%windir%\System32\DriverStore\FileRepository\hp*") do rd /s /q "%~G"
    Note: this will delete all HP's folders from the FileRepository system folder
  4. Uninstall the HP Software.
  5. Now download the latest drivers and reinstall the HP Software.

Shlomi



2019_MeetupAward_Signature_FINAL(1).png
Say thanks by clicking the Kudos thumb up in the post.
If my post resolve your problem please mark it as an Accepted Solution 🙂
champ888
New member
2 2 0 0
Message 5 of 11
1,458
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

Spoiler
 

I'm having the same issue, but with the software I was originally prompted to install with my Officejet 250 mobile when I purchased it on 31 Jan 2020.  I'm currently trying to uninstall "HP OfficeJet 250 Mobile Series Basic Device" (40.11.1148.17181) from my computer and absolutely nothing has worked.  I even tried to delete everything from the program files and sifted through the registry to delete it manually, but it relentlessly shows up under "Apps & features", and I have zero connectivity via any means with my OJ250 other than via usb cable.  The problem seems obvious; that I need to uninstall all HP drivers, and install the latest full version of software, but even the above solution doesn't work.  

When I enter the first copy/paste portion, it states "Successfully processed 4 files; Failed processing 1 files" - the failure is "C:\Windows\System32\DriverStore\FileRepository\accelerometer.inf_amd64_08b794c8e40839a9: Access is denied."

Then when I enter the next command it says "Access is denied." after every subsequent line.

 

This is really quite frustrating.

Reply
0 Kudos
Level 16
Level 16
26,394 26,118 4,659 10,260
Message 6 of 11
1,412
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

Thanks for the information @champ888.

 

Please try the following syntax instead and let me know if you may see any difference:

Spoiler
takeown /f %windir%\System32\DriverStore\FileRepository /r /d y
icacls "%windir%\System32\DriverStore\FileRepository" /grant %username%:(OI)(CI)F /T
for /d %G in ("%windir%\System32\DriverStore\FileRepository\hp*") do rd /s /q "%~G"
takeown /f %windir%\System32\DriverStore\FileRepository /A /r /d y

You may simply paste the whole text and let it work, but be sure to run the Command Prompt as Administrator, do not be scared from the commands, as it temporarily changes the ownership of every subfolder and then changes it back to the original Administrators group.

 

Please let me know if that helps, when you are done try uninstalling the HP Software and check for any difference.

 

Shlomi

2019_MeetupAward_Signature_FINAL(1).png
Say thanks by clicking the Kudos thumb up in the post.
If my post resolve your problem please mark it as an Accepted Solution 🙂
champ888
New member
2 2 0 0
Message 7 of 11
1,382
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

Nailed it; you're my hero.

Reply
0 Kudos
rhickmanjr
New member
1 1 0 0
Message 8 of 11
1,295
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

I had the same exact problem, experienced the same errors in the same sequence and this solution worked.  I had to jump through hoops to register to respond but needed to dos so inorder to thank you for this fix!   

 

Thanks!!!

Reply
0 Kudos
Level 16
Level 16
26,394 26,118 4,659 10,260
Message 9 of 11
1,275
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

You’re much welcome @champ888 and @rhickmanjr , great to see it has resolved the problem!

 

Cheers,

Shlomi

2019_MeetupAward_Signature_FINAL(1).png
Say thanks by clicking the Kudos thumb up in the post.
If my post resolve your problem please mark it as an Accepted Solution 🙂
_Ninag33
New member
1 1 0 0
Message 10 of 11
1,034
Flag Post
HP Recommended

Solved!

driverpackageuninstall returned error 5 for package I have a HP Envy 4500.

I am having this same issue but I have a HP Envy laptop as well.  Any advice?

Reply
0 Kudos
† The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation