5

If I install and then uninstall our extension through the registry everything works fine. But if I install it through the registry and then uninstall it through the browser extensions page the browser remembers it and i can't reinstall it through the registry even if I remove it and then try to reinstall it through the registry. The only way I can have the extension reinstalled is to add it manually to the extensions page. But, I don't want my users to have to do it manually. Is there a way to force install it again?

Thanks, Ben

Ben Laniado
  • 510
  • 6
  • 18
  • Is there a reason for installing it through registry? – serg May 03 '11 at 15:46
  • 1
    Hi Ben, I have exactly the same problem. I guess you've already read this http://code.google.com/chrome/extensions/external_extensions.html . The reason why you can't reinstall from the registry when user manually uninstall your extension is because chrome puts a 'blacklist' flag on your extension. The only way to turn this flag off, is that user manually install/uninstall the extension. BUT if your registry is still there, as soon as the 'blacklist' flag is off, it will auto-install your extension. – developerGuile May 04 '11 at 19:02
  • I'm trying to be able to install again even if a 'blacklist' flag is ON (because user manually uninstalled the 'external-extension'). I discussed my problem there http://stackoverflow.com/questions/5887944/auto-installing-a-google-chrome-extension-wont-work Hope we can help each other. Good luck! – developerGuile May 04 '11 at 19:09
  • This is what they say on the google FAQ **If the user uninstalls the extension through the UI, it will no longer be installed or updated on each startup. In other words, the external extension is blacklisted.** – developerGuile May 04 '11 at 20:14
  • I still didn't find a solution to the problem. I think we will go as a known issue as this is really good feature of chrome. (that we don't like but as end users we can appreciate ). – Ben Laniado May 05 '11 at 08:14

2 Answers2

5

I found a solution to the problem. But, I decided not to use it because I decided it is a good idea not to force installation after the user removed the extension. Just thought that you will want to know the solution: Turn off your Google Chrome browser go to the 'Preferences' file under: c:\users\\AppData\Local\Google\Chrome\User Data\Default there find your extension under "{Guid}" then delete everything from "{guid}" (included) to the close '}' and then save and start your browser. this hack will force chrome to check again for extensions and your extension will be on again.

Ben Laniado
  • 510
  • 6
  • 18
  • It works ! But the problem is that you have to ask user to close (or do it with a script) the browser. I guess there is no way around since chrome will overwrite the preferences files on browser close with the on saved when it opened. – developerGuile May 05 '11 at 15:00
  • What's the solution for this in MacOS? – praveenbharatsagar Sep 15 '22 at 19:48
0

I respect the Chrome policy to make the extension blacklisted in this case until the user manually adds it back through Chrome Extensions page UI. However there is another tweak available:

If you are using windows, open the 'Preferences' file in: "C:\users\AppData\Local\Google\Chrome\User Data\Default".

This is a JSON file. Look for your extension id (Guid) key with object value section. Changing the value of 'state' property from 2 to 1 in your extension Guid values section will force chrome to bring back your extension once you start chrome browser.

Note: The chrome browser must be closed completely before modifying this file.