If your running NT5 all round, could give the COM ADSI approach a try, just change the $vars as required:

Code:

break on

$username = "administrator"
$password = "******"
$hostname = "dnafx1"
$service = "alerter"

$root = GetObject("WinNT:")

if $root

$service = $root.OpenDSObject("WinNT://$hostname/$service,service",$username,$password,0)

if $service

$service.StartType = 2
$service.SetInfo()

endif

endif

exit 1



-Shawn