Sorry .. Forgot to specify the value :-)
Should set "NV ComputerName" in CurrentControlSet and "NV Hostname" in TcpIp
Services
For that mistake, I'll take off $5 :D
-----Original Message-----
From: Ky-Anh Phan
Sent: Thursday, March 14, 2002 10:54 AM
To: 'JM'; [EMAIL PROTECTED]
Subject: RE: Changing Computer Name - $20???
Is this U.S. dollars? :-)
use Win32::TieRegistry ( Delimiter => '/', ArrayValues => 0, TiedRef =>
\$Registry );
$Registry->{'LMachine/SYSTEM/CurrentControlSet/Control/ComputerName/Computer
Name/NV ComputerName'} = $name;
$Registry->{'LMachine/SYSTEM/CurrentControlSet/Services/Tcpip/Parameters/NV
Hostname'} = $name; Win32::InitiateSystemShutdown("","Rebooting the
computer",5 ,0 ,1);
-----Original Message-----
From: JM [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, March 13, 2002 8:01 PM
To: [EMAIL PROTECTED]
Subject: Changing Computer Name - $20???
Hi
I'm trying to change a computer name on a Windows 2000 PC, logged in as
Administrator. It changes the Computername ENV. Var. but does not change
the NetBIOS name. $20.00 to the first person that can help me get this code
to work properly. . .
use Win32;
use Win32::AdminMisc;
Win32::AdminMisc::SetComputerName('BLACKBOX');
Win32::InitiateSystemShutdown("","Rebooting the computer",5 ,0 ,1);
The Computer reboots properly . . .
_______________________________________________
Perl-Win32-Admin mailing list [EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
_______________________________________________
Perl-Win32-Admin mailing list [EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
_______________________________________________
Perl-Win32-Admin mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs