Jump to content











Photo
- - - - -

[Solved][script]Get stucked to make a script with InstallRite


  • Please log in to reply
32 replies to this topic

#1 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 02 February 2010 - 05:36 PM

Hi,
I'm trying to make some app-scripts and have read this link to start to making scripts :

Things to know about App-scripts
Also with the included links from this topic too.

Hmm, so i started with "MakeScript" from Pedro and successed with Peter's and Lancelot's help. But for now i thing by making App-scripts it should be have registry keys and my first script that i make with "MakeScript" doesn't have any registry keys being added. So i try to use "InstallRite" to get the registry keys, so i follow steps and exported the added registry from the "InstallRite" and make it to inf with paraglider great tool "ConvRegToInf", so i have the inf file with many registry keys inside (over 400 keys). And finally freezed at this point with so many question and unknowing about registry keys, such as what exactly keys must i use or all keys and so much another question. Totally confused and unsure to get forward. ;)

Ps: i learn and try to get the steps with installRite from this external link:
How to use InstallRite
from Robvdb and i tested it with editplus to add it into LiveXP

m4dm4Xz

#2 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 02 February 2010 - 05:51 PM

I use What Changed (free) to isolate the program's files for import and ART (not free) to capture the registry changes but I'm sure it's similar to tools you use. There is always a number of keys saved that you don't need. Any key containing \\ShellNoRoam\BagMRU or MUICache or \\Microsoft\Cryptography\RNG you can safely dump and keys with references to 'Uninstall', 'Session Information' or 'Start menu' are also OK to cut, as well as any references to local directories on your host (like where the program.exe was launched from etc.). The keys beginning with HKEY_USERS\ can usually be removed but may include keys with registration information or other user specific data so look carefully (if not sure, leave them in). Wherever you have duplicate sets of HKEY_USERS i.e. HKEY_USERS\.DEFAULT and HKEY_USERS\S-1-5-18*, you probably only need to keep the .DEFAULT entries. *If you need to import user specific keys captured from your host, be sure to change any user ID's to default, so \S-1-5-XX-xxxxxxxxxx-xxxxxxxxx-xxxxxxxxxx-xxxx\ becomes simply \S-1-5-18\. If not sure about certain keys, you can do a little investigative work in PE, manually importing them to see how they affect the program. You should always test the final reg file(s) in PE by manually importing the data (dbl-click reg files and accept prompt) to make sure there isn't some conflict (you'll get an error message if there is). Never make changes or tests like this on your host registry!! Any changes made are only in exported reg files and imported only to your PE's registry. Also, for converting reg files to wb script, I prefer reg2wbs tool ;)

:P

#3 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 02 February 2010 - 08:17 PM

Boah, that is great new knowledge for me, time to learn more and investigate about in reg-keys. :P

Thank you, Amalux. ;)

#4 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 02 February 2010 - 09:09 PM

Hi Amalux,
Can i with \\ShellNoRoam\BagMRU or MUICache references keys cut them out too, like 'Uninstall', 'Session Information' or 'Start menu' ?

I 've some example from my .ini file.
0x4, "Software\Microsoft\Windows\ShellNoRoam\BagMRU\4\0\1\0\0","NodeSlot", 0x0000000e

0x3, "Software\Microsoft\Windows\ShellNoRoam\BagMRU\4\0\1\0\0","MRUListEx",\

  ff,ff,ff,ff
I see \\ShellNoRoam\BagMRU\ but they are not ended as BagMRU but have "\4\0\1\0\0" as the end are they save to cut too?

Ps: I'm cut the registry keys out after i converted it to .ini file. ?? ;)

Thank's very much.
m4dm4Xz

#5 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 03 February 2010 - 02:55 PM

Hi m4dm4Xz,

Those entries are OK to cut but I'm not sure why you're editing reg data after converting to ini; is this required for the program you use?

#6 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 03 February 2010 - 04:57 PM

Hi m4dm4Xz,

Those entries are OK to cut but I'm not sure why you're editing reg data after converting to ini; is this required for the program you use?


Okay thank's, and about editing from the ".ini" file it's because in the first i think it's easier to edit the ini file as the output ".reg" file from "InstallRite". But i think i was wrong because i didn't see HKCU\ and another important things like in the reg file. :cheers:

And all this is because I understood the tutorial from InstallRite wrong; edited only the path in the .ini file.

Thank you, for helping forward. :P

m4dm4Xz

#7 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 03 February 2010 - 07:57 PM

Wherever you have duplicate sets of HKEY_USERS i.e. HKEY_USERS\.DEFAULT and HKEY_USERS\S-1-5-18*, you probably only need to keep the .DEFAULT entries. *If you need to import user specific keys captured from your host, be sure to change any user ID's to default, so \S-1-5-XX-xxxxxxxxxx-xxxxxxxxx-xxxxxxxxxx-xxxx\ becomes simply \S-1-5-18\.


Hmm, about HKEY_USERS\S-1-5-18 keys i didn't have anyone and is this ID key "\S-1-5-18\" be the default number if i wish to make user specific keys i must rename them to "\S-1-5-18\" is that right or must i rename it to "\S-1-5-21\ to be the default key"? (because mine ID keys are S-1-5-21-XXXXXX-XXXXX...)

And every key that have a path must be edited i.e.
"C:\Windows" to "%SystemDrive%\i386\"
and
"C:\Program Files\" to "%SystemDrive%\" but i have another path
"C:\\Documents and Settings\\tester\\Application Data\\" what should i replace?

Ps: sorry for my english :cheers:

m4dm4Xz

#8 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 04 February 2010 - 05:54 AM

starting over, previous post was confusing :P

Hmm, about HKEY_USERS\S-1-5-18 keys i didn't have anyone and is this ID key "\S-1-5-18\" be the default number if i wish to make user specific keys i must rename them to "\S-1-5-18\" is that right or must i rename it to "\S-1-5-21\ to be the default key"? (because mine ID keys are S-1-5-21-XXXXXX-XXXXX...)


In PE, you really only have one user which translates to 'S-1-5-18' ID in the registry. So if your host is:
[HKEY_USERS\S-1-5-19\Software\...] or 

[HKEY_USERS\S-1-5-21-1234567890-123456789-1234567890-1100\Software\...]
etc.

it all gets entered as
[HKEY_USERS\S-1-5-18\Software\...]
in PE registry but...

For converting to WB script, it seems all users ID's are automatically lumped together in the reg add data output (at least this is what seems to occur using reg2WBS (Peter can correct me if I'm wrong), I don't know how other tools work). I'm used to doing this by hand in PE and testing reg file input directly (mainly for portable applications setup) so it seems, at least with reg2WBS, the user ID thing is handled for you.

And every key that have a path must be edited i.e.
"C:\Windows" to "%SystemDrive%\i386\"
and
"C:\Program Files\" to "%SystemDrive%\" but i have another path
"C:\\Documents and Settings\\tester\\Application Data\\" what should i replace?

Use a good text editor for this like Notepad++ (free) which allows for changing all instances of a text string in one shot. e.g. replace all "C:\\Windows\\System32\\" with "X:\\i386\\System32\\" etc.

"C:\\Documents and Settings\\tester\\Application Data\\" moves to "C:\\Documents and Settings\\Default User\\Application Data\\"

You do use variables in the script and converting reg (.reg) files to WB script, all instances of C: become #$pSystemDrive#$p (%SystemDrive%) which works just as well for X: in PE so converting to reg add data like this:
Windows Registry Editor Version 5.00



[HKEY_CURRENT_USER\Software\Rising Sun Solutions, Inc.\Atlantis.1_x\SpellCheck]

"Systems"="C:\\Program Files\\Atlantis\\Spellcheck\\English (American).asc"

becomes
Hive_Load,Default

reg_add,0x2,"%reg%\Software\Rising Sun Solutions, Inc.\Atlantis.1_x\SpellCheck",Systems,#$pSystemDrive#$p\Program#$sFiles\Atlantis\Spellcheck\English#$s(American).asc

Hive_Unload,Default

Hope that's not more confusing, remember the conversion is done for you; you just need to edit the unnecessary stuff out of the source reg file.

:cheers:

#9 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 04 February 2010 - 10:36 AM

starting over, previous post was confusing :cheers:

....

Hope that's not more confusing, remember the conversion is done for you; you just need to edit the unnecessary stuff out of the source reg file.

:cheers:


Hi Amalux,
Thank's for explaining me that really help me much, also "reg2wbs" help me to:
1. converting from reg to script
2. user ID key things
3. and finally replace all path automatically.
So, nothing to need more; that is the perfect tool that Peter make here for convert "regs" into scripts.

Thank you very very much Amalux, for take your time here to clear my confusing.

:P

m4dm4Xz

#10 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 04 February 2010 - 11:36 AM

:cheers:

m4dm4Xz

#11 pscEx

pscEx

    Platinum Member

  • Team Reboot
  • 12707 posts
  • Location:Korschenbroich, Germany
  • Interests:What somebody else cannot do.
  •  
    European Union

Posted 04 February 2010 - 11:52 AM

Use a good text editor for this like Notepad++ (free) which allows for changing all instances of a text string in one shot. e.g. replace all "C:\\Windows\\System32\\" with "X:\\i386\\System32\\" etc.

"C:\\Documents and Settings\\tester\\Application Data\\" moves to "C:\\Documents and Settings\\Default User\\Application Data\\"

In Reg2WBS the %SystemRoot% environment variable value of your host (usually "C:\Windows") is automatically replaced by "%SystemRoot%" which will be resolved in the PE as X:\I386
if you check that (blue mark)
The replacement of user names you can define in the GUI like (red marks):
reg2wbssample.gif

Peter

#12 paraglider

paraglider

    Gold Member

  • .script developer
  • 1743 posts
  • Location:NC,USA
  •  
    United States

Posted 04 February 2010 - 12:33 PM

Of course not all programs support environment variables in registry values.

Also sometimes its the registry key name / value name that has hard coded paths in the name.

In these cases you either hard code the path like x:\i386 or you use RegAddBoot to expand when the system boots.

#13 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 04 February 2010 - 02:30 PM

I have tried "reg2wbs" from Peter but i do something wrong or the program cut off some keys as normal (it can be that i not have the knowledge why they are cut, it can be normal or right). I have tested it with some keys.
[codebox][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Path"="C:\\Program Files\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"INI directory"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"STX ACP CTL"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"eula"=dword:00000001[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Language"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"First Run"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"ReplaceX"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"ReplaceY"=dword:00000000[/codebox]and the result is :[code]Hive_Load,Defaultreg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\Install",ReplaceY,0Hive_Unload,Default[/code]
Is that normal that it gave me output only the one?

Ps: I have run it on XPSP2 X86 in his own folder and have set the following options:
1. Output Hive; Set all
2. Options; Checked "Write RegHiveLoad" and "Replace Environment strings"
3. API Style; Checked "Output API style and Replace"
4. browse the reg file and builded it.

:cheers:

m4dm4Xz



#14 pscEx

pscEx

    Platinum Member

  • Team Reboot
  • 12707 posts
  • Location:Korschenbroich, Germany
  • Interests:What somebody else cannot do.
  •  
    European Union

Posted 04 February 2010 - 02:51 PM

The *.reg you show above is not valid.

It must have the correct build rules:

1st a header:
"Windows Registry Editor Version 5.00"

then following the single entries, all separated by one and only one empty line.

The file has to be in UTF8 / Unicode.

When you edit it with an external editor, take care that you do not store it as ascii text file.

Peter

#15 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 04 February 2010 - 02:59 PM

Just saw Peter's post so I'll just give example to explain, if keys were not all the same (as in real export), would produce individule entries:
Hive_Load,Default

reg_add,0x0,%reg%\Software\Avg\Avg8

reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Install"

reg_add,0x2,"%reg%\Software\ES-Computing\EditPlus 3\Install1",Path,#$pSystemDrive#$p\Program#$sFiles\EditPlus#$s3

reg_add,0x2,"%reg%\Software\ES-Computing\EditPlus 3\Install2","INI directory",#$pSystemDrive#$p\Documents#$sand#$sSettings\tester\Application#$sData\EditPlus#$s3

reg_add,0x2,"%reg%\Software\ES-Computing\EditPlus 3\Install3","STX ACP CTL",#$pSystemDrive#$p\Documents#$sand#$sSettings\tester\Application#$sData\EditPlus#$s3

reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\Install4",eula,1

reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\Install5",Language,0

reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\Install6","First Run",0

reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\Install7",ReplaceX,0

reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\Install8",ReplaceY,0

Hive_Unload,Default

:cheers:

#16 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 04 February 2010 - 04:33 PM

1st a header:
"Windows Registry Editor Version 5.00"

Hi Peter,
i use the output from "installRite" and my header was "REGEDIT4" but sorry for my previous post that i didn't include it. In my real reg file, it's present. :P

then following the single entries, all separated by one and only one empty line.

For now i know it, thank's and i already edited like you say. I removed all two new line space to one new line space. (i don't know how to say it look at my example)
From:
[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Path"="C:\\Program Files\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"INI directory"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"
To:
[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Path"="C:\\Program Files\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"INI directory"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"
Also deleted the new line space to 1 instead 2 or 3. :cheers:

The file has to be in UTF8 / Unicode.

In the first i didn't noticed, what encode i save the file. Now, i saved it to UTF8 and i use editplus as editor. (again :cheers:)

finally i can't get the accepted output. Still the same results. :P

m4dm4Xz

Ps: i use the output from InstallRite exported added ".reg" keys. After editing i try with several encodes to save the reg; "UTF-8", "UTF-8 + BOM", "Unicode", "Unicode (UTF-8) 65001".

#17 pscEx

pscEx

    Platinum Member

  • Team Reboot
  • 12707 posts
  • Location:Korschenbroich, Germany
  • Interests:What somebody else cannot do.
  •  
    European Union

Posted 04 February 2010 - 04:45 PM

This is what I get from your .reg:
[codebox][Main] Title=reg2wbs Selected=False Level=10 Author=PSC Program 'reg2WBS' Version=000 Date=04-Feb-2010 [Process] Hive_Load,Machine reg_add,0x1,"%reg%\Classes\EditPlus 3",,EditPlus#$s3 reg_add,0x2,"%reg%\Classes\EditPlus 3\DefaultIcon",,#$pSystemDrive#$p\Program#$sFiles\EditPlus#$s3\EDITPLUS.EXE#$c-5000 reg_add,0x0,"%reg%\Classes\EditPlus 3\shell" reg_add,0x0,"%reg%\Classes\EditPlus 3\shell\open" reg_add,0x2,"%reg%\Classes\EditPlus 3\shell\open\command",,#$pSystemDrive#$p\PROGRA~1\EDITPL~1\EDITPLUS.EXE#$s#$q#$p1#$q reg_add,0x1,"%reg%\Classes\EditPlus 3\shell\open\ddeexec",,[open(#$q#$p1#$q)] reg_add,0x0,"%reg%\Classes\EditPlus 3\shell\print" reg_add,0x2,"%reg%\Classes\EditPlus 3\shell\print\command",,#$pSystemDrive#$p\PROGRA~1\EDITPL~1\EDITPLUS.EXE#$s/p#$s#$q#$p1#$q reg_add,0x1,"%reg%\Classes\EditPlus 3\shell\print\ddeexec",,[print(#$q#$p1#$q)] reg_add,0x1,"%reg%\Classes\*\shellex\ContextMenuHandlers\EditPlus 3",,{36D94110-787C-4828-9C1B-0DAFEBC36069} reg_add,0x0,"%reg%\Classes\.htm\OpenWithList\EditPlus 3\shell\open" reg_add,0x2,"%reg%\Classes\.htm\OpenWithList\EditPlus 3\shell\open\command",,#$pSystemDrive#$p\PROGRA~1\EDITPL~1\EDITPLUS.EXE#$s#$q#$p1#$q reg_add,0x1,"%reg%\Classes\.htm\OpenWithList\EditPlus 3\shell\open\ddeexec",,[open(#$q#$p1#$q)] reg_add,0x1,%reg%\Classes\Applications\EDITPLUS.EXE,, reg_add,0x0,%reg%\Classes\Applications\EDITPLUS.EXE\shell reg_add,0x0,%reg%\Classes\Applications\EDITPLUS.EXE\shell\edit reg_add,0x2,%reg%\Classes\Applications\EDITPLUS.EXE\shell\edit\command,,#$pSystemDrive#$p\PROGRA~1\EDITPL~1\EDITPLUS.EXE#$s#$q#$p1#$q reg_add,0x1,%reg%\Classes\Applications\EDITPLUS.EXE\shell\edit\ddeexec,,[open(#$q#$p1#$q)] reg_add,0x0,%reg%\Classes\Applications\EDITPLUS.EXE\shell\open reg_add,0x2,%reg%\Classes\Applications\EDITPLUS.EXE\shell\open\command,,#$pSystemDrive#$p\PROGRA~1\EDITPL~1\EDITPLUS.EXE#$s#$q#$p1#$q reg_add,0x1,%reg%\Classes\Applications\EDITPLUS.EXE\shell\open\ddeexec,,[open(#$q#$p1#$q)] reg_add,0x1,%reg%\Classes\CLSID\{36D94110-787C-4828-9C1B-0DAFEBC36069},,EditPlus#$s3 reg_add,0x1,%reg%\Classes\CLSID\{36D94110-787C-4828-9C1B-0DAFEBC36069}\InProcServer32,ThreadingModel,Apartment reg_add,0x0,"%reg%\Classes\EditPlus 3\shell" reg_add,0x0,"%reg%\Classes\EditPlus 3\shell\open" reg_add,0x0,"%reg%\Classes\EditPlus 3\shell\print" reg_add,0x0,"%reg%\Classes\.htm\OpenWithList\EditPlus 3\shell\open" reg_add,0x0,%reg%\Classes\Applications\EDITPLUS.EXE\shell reg_add,0x0,%reg%\Classes\Applications\EDITPLUS.EXE\shell\edit reg_add,0x0,%reg%\Classes\Applications\EDITPLUS.EXE\shell\open reg_add,0x0,%reg%\ES-Computing reg_add,0x0,"%reg%\ES-Computing\EditPlus 3" reg_add,0x0,"%reg%\ES-Computing\EditPlus 3\Install" Hive_Unload,Machine Hive_Load,System reg_add,0x1,%reg%\ControlSet001\Services\kmixer\Enum,0,SW\{b7eafdc0-a680-11d0-96d8-00aa0051e51d}\{9B365890-165F-11D0-A195-0020AFD156E4} Hive_Unload,System Hive_Load,Default reg_add,0x0,%reg%\Software\ES-Computing reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Association" reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\Install",ReplaceY,0 reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\0" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\1" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\10" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\11" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\2" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\3" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\4" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\5" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\6" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\7" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\8" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\Settings\9" reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars" reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Bar0",BarID,59393 reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Bar1",MRUFloatYPos,0 reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Bar2",MRUFloatYPos,0 reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Bar3",Bar#4,0 reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Bar4",BarID,59401 reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Bar5",MRUWidth,164 reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Bar6",MRUWidth,170 reg_add,0x4,"%reg%\Software\ES-Computing\EditPlus 3\ToolBars\ToolBar State-Summary",ScreenCY,600 reg_add,0x0,%reg%\Software\ES-Computing reg_add,0x0,"%reg%\Software\ES-Computing\EditPlus 3" Hive_Unload,Default [/codebox]

Peter

:cheers: ???

#18 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 04 February 2010 - 05:22 PM

That's was exactly the same that i get. But not the result that i post at the previous because i tested it with only some specific keys to see that they really not appear.
I have another test reg attached here. :cheers:

But thank you for helping forward. :P

Ps: i have tried to clear the "reg2wbs" too with deleting the "reg2WBS.ini".

:cheers:
m4dm4Xz

Attached Files



#19 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 04 February 2010 - 07:20 PM

Hi m4dm4Xz :cheers:

Sometimes the best way to learn is to see how someone else does it; here's an example. Attached File  ep3.zip   1.23MB   459 downloads
I couldn't find your exact version but should be similar. Also, I wasn't sure about the "PROGRA~1\\EDITPL~1" entries (may work) so replaced with "Program Files\\EditPlus3" just to be safe.

:P

#20 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 04 February 2010 - 08:17 PM

Hi Amalux,
I think i get it from your example and from my testing with another output reg from another programs instead "installRite" give me the answer that "reg2wbs" should be confused with the duplicated keys.

then following the single entries, all separated by one and only one empty line.

Or it can be that i understood wrong and confused self too. :P :P

But an example for this makes my very clear:
[codebox]REGEDIT4[HKEY_CURRENT_USER\Software\ES-Computing][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Path"="C:\\Program Files\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"INI directory"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"STX ACP CTL"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"eula"=dword:00000001[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Language"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"First Run"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Placement"=hex:2c,00,00,00,02,00,00,00,03,00,00,00,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,16,00,00,00,1d,00,00,00,6e,02,00,00,b1,01,00,00,[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Full Screen"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Window List"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Function List"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Open Remote"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Expand"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Project"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"FindX"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"FindY"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"ReplaceX"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"ReplaceY"=dword:00000000[/codebox][b]and this should be the same reg but dump the same key into one:[/b][codebox]REGEDIT4[HKEY_CURRENT_USER\Software\ES-Computing][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install][HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Path"="C:\\Program Files\\EditPlus 3""INI directory"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3""STX ACP CTL"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3""eula"=dword:00000001"Language"=dword:00000000"First Run"=dword:00000000"Placement"=hex:2c,00,00,00,02,00,00,00,03,00,00,00,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,ff,16,00,00,00,1d,00,00,00,6e,02,00,00,b1,01,00,00,"Full Screen"=dword:00000000"Window List"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,"Function List"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,"Open Remote"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,"Expand"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,"Project"=hex:00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,"FindX"=dword:00000000"FindY"=dword:00000000"ReplaceX"=dword:00000000"ReplaceY"=dword:00000000[/codebox]And "WOLLA" (i don't know but my father like to say it often if successed something) with the second registry i can convert it into script successfully 99% keys included only one that seems be duplicate, so "reg2wbs" choose the last key with the value keys.[code]"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"[/code]
Finally i can do it, with your and peters help.
Thank you very much.

Ps: I really don't know about this "duplicate thing" but for me it's new and i dont' know of any other user that they know about this "duplicate key thing" or not. But now i know to handle with this (more than before). :cheers:

:cheers:

m4dm4Xz

#21 amalux

amalux

    Platinum Member

  • Tutorial Writer
  • 2813 posts
  •  
    United States

Posted 04 February 2010 - 09:08 PM

I really don't know about this "duplicate thing" but for me it's new and i dont' know of any other user that they know about this "duplicate key thing" or not. But now i know to handle with this (more than before). :cheers:

Sorry if there's been some mis-understanding back and forth, I think I understand the problem now, this 'duplicate' key:
[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]
repeating over and over simply overwrites each previous entry. What I don't understand is why it's there in your reg examples. If this is output from some program you're using, I suggest using a different program as this should not be happening.

:P

#22 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 04 February 2010 - 09:27 PM

[quote name='amalux' post='90511' date='Feb 4 2010, 10:08 PM']Sorry if there's been some mis-understanding back and forth, I think I understand the problem now, this 'duplicate' key:
...[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Path"="C:\\Program Files\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"INI directory"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"STX ACP CTL"="C:\\Documents and Settings\\tester\\Application Data\\EditPlus 3"[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"eula"=dword:00000001[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"Language"=dword:00000000[HKEY_CURRENT_USER\Software\ES-Computing\EditPlus 3\Install]"First Run"=dword:00000000....
I think the "InstallRite" captured as monitored one file by one and so cames the duplicate keys or same keys but with different value and after that when i exported it, it came out like the time be captured.Also there are two ways; use a another reg capture program or dump reg keys together. (not too hard i think if it's not too much). Because "InstallRite" is a very useful&easy tool and popular program that success many scripts before. :PHmm, but i think i will try several capture registry programs to find best (for me) usage. :cheers:

Have tried a trial version from "ART" too, but can't exported the compared keys. I think that's can be done only in the full version. :cheers:

:P

m4dm4Xz

#23 pscEx

pscEx

    Platinum Member

  • Team Reboot
  • 12707 posts
  • Location:Korschenbroich, Germany
  • Interests:What somebody else cannot do.
  •  
    European Union

Posted 04 February 2010 - 10:49 PM

You (or InstallRite) found a bug!
Let's assume that there is a .reg file containing:
Windows Registry Editor Version 5.00

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #1"="My first value"

 "Value #2"="My second value"

 "Value #x"="My last value"
or
Windows Registry Editor Version 5.00

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #1"="My first value"

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #2"="My second value"

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #x"="My last value"

Both regs are logically identical. And the result by Reg2WBS should be the same.

But the result is not:

#1 brings:
Hive_Load,Software

 reg_add,0x1,%reg%\PSC,"Value #1",My#$sfirst#$svalue

 reg_add,0x1,%reg%\PSC,"Value #2",My#$ssecond#$svalue

 reg_add,0x1,%reg%\PSC,"Value #x",My#$slast#$svalue

 Hive_Unload,Software
and #2 brings only
Hive_Load,Software

 reg_add,0x1,%reg%\PSC,"Value #x",My#$slast#$svalue

 Hive_Unload,Software

It took a while for me to understand your (mine!) issue.
Thanks a lot for your patience!

Tomorrow I'm going to fix.

Peter

#24 Lancelot

Lancelot

    Frequent Member

  • .script developer
  • 5013 posts
  • Location:Turkiye/Izmir
  • Interests:*Mechanical stuff and Physics,
    *LiveXP, BartPE, SherpyaXPE,
    *Basketball and Looong Walking,
    *Buying outwear for my girlf (Reason: Girls are stupid about buying bad stuff to make themselves uglier :))
    *Girls (Lyric: Girl,...., You will be a womann, Soon)
    *Answering questions for "Meaning of life",
    *Helping people,

    Kung with LiveXP, Fu with Peter :)
  •  
    Turkey

Posted 04 February 2010 - 11:34 PM

@psc

You (or InstallRite) found a bug!

I was just informing but I see you already noticed ;)

@m4dm4Xz
Here is my favorite route:
for regcompare,
I use paraglider's Regshot to see which registry keys written
than I use regedit and explore to the registry key(s), export to .reg file :P (maybe not needed, but it is my habit)

for filescompare,
for most applications, mostly files are there ;). (at one of the Usual Suspects)

You are going fine, already making contributions that results with fixes and addings, thanks a lot :P

#25 m4dm4Xz

m4dm4Xz

    Member

  • Members
  • 76 posts
  • Location:Bangkok
  • Interests:LiveXP only enough
  •  
    Thailand

Posted 05 February 2010 - 12:07 AM

You (or InstallRite) found a bug!
Let's assume that there is a .reg file containing:

Windows Registry Editor Version 5.00

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #1"="My first value"

 "Value #2"="My second value"

 "Value #x"="My last value"
or
Windows Registry Editor Version 5.00

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #1"="My first value"

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #2"="My second value"

 

 [HKEY_LOCAL_MACHINE\SOFTWARE\PSC]

 "Value #x"="My last value"

Both regs are logically identical. And the result by Reg2WBS should be the same.

But the result is not:

#1 brings:
Hive_Load,Software

 reg_add,0x1,%reg%\PSC,"Value #1",My#$sfirst#$svalue

 reg_add,0x1,%reg%\PSC,"Value #2",My#$ssecond#$svalue

 reg_add,0x1,%reg%\PSC,"Value #x",My#$slast#$svalue

 Hive_Unload,Software
and #2 brings only
Hive_Load,Software

 reg_add,0x1,%reg%\PSC,"Value #x",My#$slast#$svalue

 Hive_Unload,Software

It took a while for me to understand your (mine!) issue.
Thanks a lot for your patience!

Tomorrow I'm going to fix.

Peter


Hi Peter and Lancelot,
@Peter
As i say i don't know about that (about the duplicate key things; it can be normal or can be unnormal with "reg2wbs", actually it writes the same key over and over to the finish like Amalux sayed) and my english is poor, sorry. ;)

@Lancelot
I just used paraglider's "regshot" working greatly and for filecompare i used your zipped version and import them into the script with winbuilder, i just found much things in winbuilder like interface, description and much more to play. In the first i think they start to write a script about [MAIN] [PROCESS] etc. with a editor. :P

Thank's thank's thank's

;)

m4dm4Xz




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users