cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
SteveoChicago
Flexera Alumni

Running VP Script after uninstall

Hi,

I hope this is just something I'm thinking too much about.

I've created a transform for Adobe Reader 9 and want to run a vb script after the uninstall to replace a couple registry entries that get removed.

I created a custom action and store it in the binary table. Then I choose the source vbs file and run Synchronous (checking the exit code). It runs in deferred mode (maybe it's not available in this mode?). I use the Install Execute Sequence After InstallInitialize with the REMOVE="ALL" condition.

This should work yes?

Thanks in advance!
Labels (1)
0 Kudos
(4) Replies
RobertDickau
Flexera Alumni

It depends what you mean by "run after the uninstall"; perhaps move the action to after the RemoveRegistryValues action?

If nothing else, creating an MSI log file will show if and when the action is being called, and so on. VBScript actions that modify the target system are sometimes stopped by anti-malware scanners, so that's another possibility.
0 Kudos
SteveoChicago
Flexera Alumni

To clarify my previous entry...What I meant by "run after the uninstall" is, I'm attempting to restore a few registry entries that get removed when Adobe Reader 9 is uninstalled via ARP. Apparently, it's removing registry keys from an Acrobat 7 install. Acrobat 7, when launched, self heals. I want to restore the keys the Reader 9 uninstall removes. I thought I could just add a custom action to perform this task in my transform. If I uninstall Reader 9, then manually run my vbs to restore the keys, Acrobat launches without self healing. Exactly what I would like to happen 🙂

I'm testing this on my VM machine too so there's no anti-malware. What's also interesting is that if I change my VBS to add a random registry key, that key is added to HKCR where the other keys would be.

That tells me my script is working but may just be in the wrong place. I think I've tried almost everywhere in the execute sequence.

Another thing I tried is changing the registry Components value of Shared and Permanent to YES. I thought doing would will tell the msi script to not remove the components/keys.

Hope this helps,
Thx!
0 Kudos
RobertDickau
Flexera Alumni

Have you created an MSI log file to verify that your action is being called? The condition REMOVE="ALL" is valid only after InstallValidate, and registry information is uninstalled when RemoveRegistryValues runs.

If that doesn't help, perhaps post part of your VBScript action, and someone in the community here might see something?
0 Kudos
SteveoChicago
Flexera Alumni

Well it's working 🙂 I set the custom action as deferred and placed it near the end and after InstallValidate. I must have had it in a different location where it was being executed before RemoveRegistry so the change would get wiped out.

Thanks again!
0 Kudos