Jump to content

Recommended Posts

Posted (edited)

Hi! all

I'm trying to work out some code to turn on the video accelerators and the other enhancers and I need to know what is the correct syntax to use to pull the value of the register string \Device\Video0 in the key VIDEO..

just dropping the \Device\Video0 in the normal way the WshShell.RegRead( thinks it is looking in the device key for the Video0 reg string

I have tried the other programs posted but they just don't work in the silent install mode,, Not even close,,

So it is time to dig a little and make one..

Once I get past this I will be able to finish the rest of the code..

I need this value so I can strip the /0000 off the end or what ever number gets put in there,,,

I also think that I will be able to just delete the Axel.level key this way it will work for everyone..

LOl I have the rest of the keys to finish the script it is just this is one spot I can't find the correct syntax for..

On Error Resume Next

DIM PNPDeviceID, VideoID, ClassGUID, Driver, Level,Acceler,Video0,Bingo

strComputer = "."

Set objWMIService = GetObject("winmgmts:" & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")

Set colItems = objWMIService.ExecQuery("Select * from Win32_VideoController")

Wscript.Echo "Number of Video Controllers: " & colItems.Count

For Each objItem in colItems

PNPDeviceID = "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Enum\" & objItem.PNPDeviceID

Set WshShell = WScript.CreateObject("WScript.Shell")

VideoID = WshShell.RegRead(PNPDeviceID & "\Device Parameters\VideoID")

ClassGUID = WshShell.RegRead(PNPDeviceID & "\ClassGUID")

Driver = WshShell.RegRead(PNPDeviceID & "\Driver")

Level = "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Video\" & VideoID & "\0000\Acceleration.Level"

Acceler = WshShell.RegRead(Level)

Video0 = WshShell.RegRead("HKEY_LOCAL_MACHINE\HARDWARE\DEVICEMAP\VIDEO\ \Device\Video0")

WScript.Echo Video0

Next

If you are confused look in the register here

HKEY_LOCAL_MACHINE\HARDWARE\DEVICEMAP\VIDEO\

then look at the Reg string \Device\Video

you will see it...

I need to know how to make it look at the \Device\Video as the reg string and not a key called Device with a reg string called Video0..

Once I get the correct syntax I can change the thread to read Silent Install

How to turn Enable video accelerator to full and Enable directdraw , Direct3D and AGP texture

Edited by Coolsights2000

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
  • Recently Browsing   0 members

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