Importing .Reg Key into HKEY_CURRENT_USER with Wise Package Studio 8

I've been working on my software package for Avaya CMS Supervisor R17 and I've got everything working with the exeception of my registry key import. I've tried various ways to complete this task:

1) Tried copying the .reg file to the temp drive and the executing the file from that location. This work while running as a user, but not as an admin. This package will be pushed down by SCCM so it'll need to be imported as an admin

2) Tried using the built-in functionality of Wise studio to "Edit Registry" and that was a complete failure it didn't import the key at all

3) I created a VBS script to attempt to handle the entry as well, but only part of the key installed on Windows 7 and nothing imported on Windows XP. I've attached the script code to see if maybe I've mis-written something:

'Import Registry Settings

set oFile  = CreateObject("scripting.FileSystemObject")   
set oShell = CreateObject("wscript.shell")
    sRegFile = "\\sccm-repo\packagecode\Avaya\CMS Supervisor R17\Avaya_R17_Server.reg"
        if oFile.FileExists(sregfile) then
        iReturn = oShell.Run("regedit.exe /s" & sRegFile)
            if iReturn <> 0 then
              wscript.echo "Import Reg Settings Failed! " & err.number & ":" & err.description
            end if
        wscript.echo "Registry Import Failed."
    end if

set ofile = nothing
set oshell = nothing

If anyone has any suggestions I might try I could use some assistance. The whole purpose of the registry key is to completely automate the installer so the user doesn't have to add the avaya servers when they launch the first time. This will make it a complete hands off installer if I can get the key to import.

0 Comments   [ + ] Show comments

Answers (1)

Posted by: rileyz 10 years ago
Red Belt

Ok, I think your going about this all wrong.

In Wise Package Studio (yuck!) you can import reg files, and it will work. Your making it harder for yourself by using VBS since there is functionality to do in the MSI/Windows Installer. 

What I think is happning is your importing the registry keys into the HKCU, and you havent leveraged Windows Installer to populate this into the nessary User Profiles.

First thing we need to know are the registry keys, if you could update your question above that would be great, dont forget to change the IP addresses etc - security and all that. This is just to confrm that the keys are HKCU.

Edit: just saw it was HKCU, i wrote a whole section it didnt post! Grrrr ):


Anyway in summary...

  1. Import your registry key into a single component
  2. create a dummy registry key.
    ie <name of component> with the value of KeyPath or something.
  3. Set that dummy reg key as the "Key Path" 
  4. Change your shortcuts to advistised shortcuts
That should do the job hopefully.
I wrote better instructions, but it failed to post which was lame...

  • Here is my reg key info:
    Windows Registry Editor Version 5.00


    I'd love to learn a new way of doing this. I myself haven't worked with the Windows Installer. Do you have any instructional information that would help me create the reg key in this fashion? - tegatron420 10 years ago
    • aha, an opportunity for blatant self-promotion.. ;)
      Check out my blog on ITNinja on the topic of user settings here: http://www.itninja.com/blog/view/a-general-approach-to-software-packaging-propagating-user-settings - pjgeutjens 10 years ago
      • +1
        I couldn't find anything decent to link to, gland you have something, why didn't google find you post!?

        Tegatron420, I think you need to get a good foundation in Repackaging, have a look on youtube and here for video resources, I reckon after about 4 hours (taking a guess here) you will start to get the jist of things. Its quite hard to explain something when you dont have a basic grounding on the technology.

        This is super old, but it will give you a good grounding.
        http://www.dawnstar.com.au/wpshelp/dl/WPS%20for%20Newbies.pdf - rileyz 10 years ago

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

View more:


This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ