Hi..i created an update for alreday existing package.This update is just few registry entries pointing to new server location.
My package works fine but in few systems, HKCU entries are overwriting HKLM entries, so users do not see updated registries.They
still see the old server entry in registries.I do not understand why HKCU is overwriting HKLM.
Another thing is I created active setup to delete HKCU\Software\(MyApplication) entries from the registry.Active setup does run but
it does not delete the HKCU entries.However, when I do it using vb script it works.Is there any reason why it works with VB Script and why not with the msi.

0 Comments   [ + ] Show Comments


Please log in to comment

Community Chosen Answer


Hey Deepali,


HKCU always take presidence over HKLM because it is a users choice over machine choice in customization.

VBScript gets the details of the user through shell while the active setup is run and others do not. So VBScript always works.



Answered 06/20/2013 by: piyushnasa
Red Belt

Please log in to comment



What do you mean "HKCU is overwriting HKLM"?

Have you tried running manually the msi to see if it works as intended before placing in Active Setup? You can also log the msi temporarily for troubleshooting purpose.

Answered 06/18/2013 by: SnowLyric
Second Degree Brown Belt

  • whatever was the registry entries for the previous install of the application, it remains the same, though it should change for my patch as it puts new regsitry entries...this means it is taking old entries from HKCU...no manually also not deleting...it only works with script
    • If manual install doesn't work then Active setup also doesn't. You would have to fix the msi first or you can also use your vb script in Active setup. Just ensure that it tries to update only hkcu entries. It could also be that your original package to update hklm entries doesn't run properly on few systems you're having problem with.
  • I came to know that "Prevent access to registry editing tools policy" is set for the users.I came to know that the wxp version of regedt.exe does not
    check the policy settings so it works for XP machines.However, in Vista, it checkes this policy and as editing is disabled, my msi fails.
    But the script to delete HKCU entries from the registry is running fine.
    If registry is disabled, how is my script able to do it.
    • That's interesting. What command does the script use to modify registry?
Please log in to comment

How did you call the VBScript in Active Setup. You have to use the commad: wscript.exe script.vbs or csript.exe script.vbs.


Answered 06/19/2013 by: terebent
Brown Belt

  • yes...i Did the same and it is working...but my question was how is it working with vb script and not if i directly write the delete command in StubPath...i think Piyush answerd my question :)
Please log in to comment
Answer this question or Comment on this question for clarity