- or download this
package PerlSvc;
use Win32::Service;
...
use DBI;
use DBD::ODBC;
use Win32::EventLog;
- or download this
# the short name by which your service will be known (cannot be 'my')
- or download this
${$_}{'CurrentState'}
- or download this
$dsn="driver=\{SQL Server\}\;Server=$srv\;UID\=$uid\;PWD\=$pwd\;";
- or download this
$exec=$dbh->prepare("...");
$exec->execute;
- or download this
$exec=$dbh->prepare("... values ('$cn', '$sname', $state)");
- or download this
$exec->finish;}else{
- or download this
}
}else
- or download this
unless (${$_} eq "1"){
- or download this
$dsn="driver=\{SQL Server\}\;Server=$srv\;UID\=$uid\;PWD\=
+$pwd\;";
- or download this
}
sleep(5);
}
}
- or download this
Win32::Service::GetServices("", \%tmp);
...
if (Win32::Service::GetStatus("",$_,\%{$_})){
- or download this
"$DisplayName"
- or download this
print "No help available.\n";