Here is another option: Place a shortcut into
c:\Documents and Settings\All Users\Start Menu\Programs\Startup. Get it to
point to c:\tools\netlogon.bat, then place these lines into netlogon.bat:
@echo off
Rem School parameters
set S-IP=192.168.1.15
set S_Mask=255.255.255.0
set S_DNS=192.168.1.254
set S_Gateway=192.168.1.254
set Server=192.168.1.1
Rem Home parameters
set H-IP=192.168.0.25
set H_Mask=255.255.255.0
set H_DNS=192.168.0.254
set H_Gateway=192.168.0.254
Preset IP parameters
set IP=%S-IP%
set Mask=%S_Mask%
set DNS=%S_DNS%
set Gateway=%S_Gateway%
ping %Server% -n 1 | find /i "bytes=" > nul && goto Action
set IP=%H_IP%
set Mask=%H_Mask%
set DNS=%H_DNS%
set Gateway=%H_Gateway%
:Action
netsh interface ip set address Local static %IP% %Mask% %Gateway% 1
netsh interface ip set dns "Local Area Connection" static %DNS% primary
I have tested the above code in principle (but not in this configuration).
To set a default printer, try this:
rundll32 printui.dll,PrintUIEntry /y /n \\<server>\<printername>
I have not tested this.
You could also use the Task Scheduler to invoke the above script at boot
time rather than at logon time.
Luke Tarrant said:
Well I had already considered dual boot option, however its not one i can
use due to limited disk size of laptop. It only has a 4GB hard drive.
I will try DHCP for the moment, however the school gateway has to be set
manually but DHCP assigns IPs ok.
Not so keen on other software option. However if DHCP doesnt work well i
may have to result to this option.
ICT = Information Communication Technology. Meaning i teach computers. Its
mainly just how to use MS Office and navigate around windows.