CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Nov 2001
    Location
    USA, Florida
    Posts
    60

    Is there a way to update Window's registry in Cmd (Commad/Dos/Emulator) mode?

    Hi all,

    Is there a way to update Window's registry in Cmd (Commad/Dos/Emulator) mode?

    Thank you,

    Biasha

  2. #2
    Join Date
    Nov 2002
    Posts
    13
    Hi Biasha,
    The Registry Editor REGEDIT.EXE can take command line parameters. You can put the registry entries in a text file with an extension .reg . Lets assume that you want to execute notepad.exe when the system boots up, you can put the following entries in a text file named startup.reg

    REGEDIT4
    [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run]
    "Notepad"="notepad.exe"


    In the command line, execute "regedit /s startup.reg ". The 's' switch will make the registry merge silent. Make sure that the file startup.reg is in the current directory of specify the full path name to the file startup.reg.

    -Raj

  3. #3
    Join Date
    Nov 2001
    Location
    USA, Florida
    Posts
    60
    Great Suggestion,

    thanks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured