/build/static/layout/Breadcrumb_cap_w.png

I want to write a VB script to check certain registry present on build or not.

VBscript that will open up regedit for me and let me cross check the values that should be there or not and simillarly files at some locations as well as those are correct with version and naming.

I want to want to avoid manual clicks in regedit, want to dorectly go to that particular registry.

 

 


0 Comments   [ + ] Show comments

Answers (1)

Posted by: sparky86 11 years ago
Fourth Degree Brown Belt
2

this maybe what you're looking for

http://stackoverflow.com/questions/137182/how-to-launch-windows-regedit-with-certain-path

i would generally do something like the following for checking machines for a registry using psexec where Computers.txt would contain the list of machines i need to check

C:\psexec @computers.txt -c regcheck.bat

Regcheck.bat

@echo off

setlocal

set regpath=HKLM\

set regvalue=

set regdata=

reg query "%regpath%" /v "%regvalue%" | find /i "%regdata%"

if errorlevel 0 GOTO FOUND

Echo %Computername% Registry Not Found >> <text file>

:FOUND

Echo %Computername% Registry Found >> <text file>


Comments:
  • Hey thanks for the reply but i am looking for easy method to open regedit, which will open a location which matches my keyword value..no manual openings - appfreak 11 years ago
  • I hv found Reg query function but its not working well ....?? - appfreak 11 years ago
    • can you explain what is not working well in the reg query funciton - Sujit J 11 years ago
      • Coudnt able to launch a valid query through it so getting error message every time invalid input,,please suggest - appfreak 11 years ago
  • Can you explain in detail the query used so that something can be suggested on it. Also how are you testing the query. - Sujit J 11 years ago
 
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