need help regarding vbs scripting

By nxsubbeh ·
Really need some help here .. i would like to ask that whether is it possible to auto create the following registry(pc name) using vbs script is like something
PC NAME:nxsubbeh1
PC NAME:nxsubbeh2
and so on
cause currently im using the *IF* and *THEN*
and i need the registry in the same folder wit it too ..
strUserIn = InputBox("PC NUMBER")
set oShell = CreateObject("WScript.Shell")
if strUserIn = 1 then"regedit /s 1.reg"
elseif strUserIn = 2 then"regedit /s 2.reg"
elseif strUserIn = 3 then"regedit /s 3.reg"
end if

Windows Registry Editor Version 5.00



is it possible by using the vbs script i can auto create the registry.. PLEASE REALLY NEED HELP.. THANKS..

This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Answers

Collapse -

A word or two of advice

by neilb@uk In reply to need help regarding vbs s ...

You would be better off making changes to CurrentControlSet. Although this is generally a pointer to ControlSet001, this is not ALWAYS the case!

However, changing the name of a standalone PC programmatically is pretty easy but I can't really see why you'd want to. Changing it for a Domain workstation is another matter entirely as you would need to remove it from the Domain, change the name and put it back and I'd even recommend as quick SID change as well!

What do you actually want to achieve?

Neil :)

Related Discussions

Related Forums