Solved

WSH/VBScript - How do I add a QWORD value to the registry

Posted on 2004-04-22
6
1,268 Views
Last Modified: 2012-05-04
I need to add a QWORD value to the registry, and have only found a WSH method to write up to DWORDS (objReg.RegWrite) to the reg.  I need to add a QWORD binary value of 0.  
0
Comment
Question by:swrona
  • 3
6 Comments
 
LVL 22

Expert Comment

by:cookre
ID: 10889758
Alas, MS has seen fit to make it more difficult to create non-reg_dword, non-reg_sz registry entries.  For anything other than reg_sz and reg_dword, you'll have to make a call to RegSetValueEx().

Unfortunately, not being a VBSer, I don't know if API calls are possible.
0
 

Author Comment

by:swrona
ID: 10890480
RegSetValueEx is a VB method, not VBS.  8^(
0
 
LVL 22

Expert Comment

by:cookre
ID: 10893043
Just thought of another possibility - make a .reg file then import it.

For example:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\EE\Testy]
"woohoo"=hex:0f,fa,b0

creates a REG_BINARY value of three bytes.

0
 
LVL 22

Accepted Solution

by:
cookre earned 125 total points
ID: 10895435
Or, for a 64-bit value, for example

"woohoo"=hex:01,00,00,00,00,00,00,00

for a little-endian 64-bit 1
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Suggested Solutions

Introduction: Recently, I got a requirement to zip all files individually with batch file script in Windows OS. I don't know much about scripting, but I searched Google and found a lot of examples and websites to complete my task. Finally, I was ab…
Use this article to create a batch file to backup a Microsoft SQL Server database to a Windows folder.  The folder can be on the local hard drive or on a network share.  This batch file will query the SQL server to get the current date & time and wi…
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now