Some help with scripting

Grimmda

2[H]4U
Joined
Jul 1, 2003
Messages
3,130
I'm posting this here because I'm more of an OS guy than a programmer and yet I feel it's something an OS guy can come up with pretty easy.

I need to grab a computers host name from WMI and pass it into a registry entry that gets run.

No third party software is a requirement for this.

I'm thinking somehow just a simple batch file that polls the post name that passes it into a command line entry to modify the registry. Here's a paste of the registry entry I want to be dynamically entered once I drop an image onto a PC:

REGEDIT4
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]
"DefaultUserName"="defaultusername"
"DefaultDomainName"="localcomputername"
"LegalNoticeCaption"=""
"LegalNoticeText"=""
"DefaultPassword"="mypassword"
"AutoAdminLogon"="1"
"DontDisplayLastUserName"="0"

I want the script to pull the host name and drop it into "DefaultDomainName" so that I can configure my image to run the script, identify the PC name, alter this script, run it and then the next time the PC boots up it'll auto log into said PC using the default username I specify.

It's gray and cold outside and my brain is stuck in the mud after lunch (Rueben Sandwich).
 
Back
Top