troubleshooting Question

Parsing registry keys with vbscript

Avatar of MidnightOne
MidnightOneFlag for United States of America asked on
VB Script
2 Comments1 Solution929 ViewsLast Modified:
Again, I'm a relative n00b with vbscript. Be gentle with me. :-)

As part of an ongoing script it loads the value of from a particular registry key:

office2007DigitalProductId = objShell.RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\12.0\Registration\{90120000-0030-0000-0000-0000000FF1CE}\DigitalProductId")

The GUID portion of this key ( the {9012000-...} portion ) is sadly different depending on installed options, language, and revision numbers; as a result, any version of Office 2007 other than Enterprise Edition in English on a Volume License Key won't be read.

I'd rather not add the 2000+ possible regkey values, but have the script read that GUID and parse it. Essentially, I need to be able to read the GUID and be able to parse that value using information from

How would I read the key HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\12.0\Registration\ and have that pull up the GUID key underneath is so I can run that through a separate code to parse for the actual installed product?

Manager, IT
Join our community to see this answer!
Unlock 1 Answer and 2 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros