|
Answer» Dear all,
i'm very new to batch files. I currently have to come in at the weekend and test machines after they have been moved. I log on as admin and have to use a tiny program which resets the users WINLOGON:
editbox "User ID" "Please enter the user's ID"
regset "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\WINDOWS NT\CurrentVersion\Winlogon" DefaultUserName %result% regset "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" DefaultDomainName EUR GOTO EOF
:EOF
i would like to know how to run the program and then for the paste funtion to AUTOMATICALLY insert the users logon that i have 'copied' before logging on as an administrator.
i hope this makes sense!?
i have this in my bat file so far...
start l:\ecr_temp\UsernameReset.wbt
which i have tested and it starts up the RIGHT thing, but then would like an automatic 'paste' to be actioned into that box, is this possible?
many thanks in advanced.
Ricky Cut and Paste is a Windows function. Neither VBScript or the Windows Script Host supports the clipboard, so you'd have to create an instance of Internet Explorer which seems to be able to do everything.
You can check this example in the Script Center for the technique to use.
Good luck.
|