The server supports the usual COM server self-registration commands:
- /RegServer or -RegServer
- /Service or -Service
- /UnregServer or - UnregServer
The argument handling is case insensitive.
In Installers the DANSrv executable can be started with the appropriate command line arguments.
To do the registration manually a BAT file or a shortcut to the DANSrv executable needs to be created with the appropriate command line arguments.
To simplify the regular registration as the process the RegServer.exe utility is provided.
Server registered as Windows Service
The DANSrv runs as a Windows service when its registered with /Service.
Sample: DANSrv.exe /Service respectively DANSrvNet4.exe /Service
By default the Windows service is set for Manual start mode. In this mode the service is started when the first client connects. The service keeps running after the client disconnects. it has to be manually stopped.
The command line argument /AutoStart can be added to set Automatic start mode. The service is started at Windows startup. The server starts into full working mode without a client being connected.
Sample: DANSrv.exe /Service /AutoStart respectively DANSrvNet4.exe /Service /AutoStart
Server registered as Process
The DANSrv runs as a regular process when its registered with /RegServer.
Sample: DANSrv.exe /RegServer respectively DANSrvNet4.exe /RegServer
DCOM starts the process when a client connects.
The process can also be started manually by executing the DANSrv.exe file. In default mode the server starts only partially. The plug-in method CreateServerItems is NOT called before a client connects.
The command line argument /FullStart can be added to force full startup without a client being connected. This may be helpful in the debugging phase and useful in some applications.
Sample: DANSrv.exe /RegServer /FullStart respectively DANSrvNet4.exe /RegServer /FullStart
The FullStart mode can also be requested from the plug-in DLL by setting the ExeStartMode argument of the GetModeDefinitions method.