Jump to content

Registrykey save in file


Markir
 Share

Recommended Posts

Hello everybody,

how can I save a registry key in a file?

I look at the autoit help and i find this code:

$var = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Siemens\HiPathCTI\Admin", "")

I want to save all informations from HKEY_LOCAL_MACHINE\SOFTWARE\Siemens\HiPathCTI\Admin in a file test.reg

I hope that somebody can help me.

Link to comment
Share on other sites

  • Developers

Hello everybody,

how can I save a registry key in a file?

I look at the autoit help and i find this code:

$var = RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Siemens\HiPathCTI\Admin", "")

I want to save all informations from HKEY_LOCAL_MACHINE\SOFTWARE\Siemens\HiPathCTI\Admin in a file test.reg

I hope that somebody can help me.

<{POST_SNAPBACK}>

FileWriteLine("filename",$var)

SciTE4AutoIt3 Full installer Download page   - Beta files       Read before posting     How to post scriptsource   Forum etiquette  Forum Rules 
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Link to comment
Share on other sites

Thank you all

@quietus24

I have coded this:

#include <GUIConstants.au3>

GUICreate("HiPath CAP 3.0 Einstellungen") ; will create a dialog box that when displayed is centered

Opt("GUICoordMode",2)

GUICtrlCreateLabel ("XML PS", 10, 10, 50)

GUICtrlCreateButton ("Registrykey exportieren", -10, 340, 50)

Run ('regedit.exe /e c:\test.reg "HKEY_LOCAL_MACHINE\SOFTWARE\Siemens\HiPathCTI\Admin"')

GUICtrlCreateButton ( "Registrykey importieren", 0, -1)

Run ('regedit.exe /i c:\test.reg "HKEY_LOCAL_MACHINE\SOFTWARE\Siemens\HiPathCTI\Admin"')

GUISetState () ; will display an dialog box with 2 button

; Run the GUI until the dialog is closed

While 1

$msg = GUIGetMsg()

If $msg = $GUI_EVENT_CLOSE Then ExitLoop

Wend

But then I run this script, there is a messagbox to import the key, but I want to choose if I want to export or import. Can you help me, please?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...