G
Guest
I have a simple service written in VB.net that can be installed and removed
successfully using srvinst. I'd like to make this file self installing though
(for example, run from the command line with an argument to get it
instantiated in the SCM). I've done this in the past by calling createprocess
WinAPI directly... but I'm guessing there must be a way to do this better in
VB.Net. I began looking at calling the Install method on ServiceInstaller and
ServiceProcessInstaller, but anything I try fails with a crash. From what I
can tell, MS does not expect you to write to these methods as they are to be
called by install programs. Usage and examples are hard to find.
Does anybody know how to call the ServiceInstall and ServiceProcessInstall
methods to install the service successfully?
successfully using srvinst. I'd like to make this file self installing though
(for example, run from the command line with an argument to get it
instantiated in the SCM). I've done this in the past by calling createprocess
WinAPI directly... but I'm guessing there must be a way to do this better in
VB.Net. I began looking at calling the Install method on ServiceInstaller and
ServiceProcessInstaller, but anything I try fails with a crash. From what I
can tell, MS does not expect you to write to these methods as they are to be
called by install programs. Usage and examples are hard to find.
Does anybody know how to call the ServiceInstall and ServiceProcessInstall
methods to install the service successfully?