How to set a fixed parameters from SCM?  
Author Message
enric vives





PostPosted: Common Language Runtime, How to set a fixed parameters from SCM? Top

Hi everyone,

Primary platform is .Framework 2.0

We've built a Windows Service by means of VB .NET. That services works properly.

Issue comes when after installation we raise for first time using two parameters in the Start Parameters textbox. Up to there everything's gonna fine but when that server do a reboot then that same service fail because these parameters are dissapeared.

Does anyone ever suffered this odd behaviour

How do I set a fix parameters forever from Service Control Manager I mean, the same way that you do with user and password.

From my OnStart method I pick up them without problems.

I can't workout with this issue. I'm stuck.

Any ideas

Thanks in advance,




.NET Development5  
 
 
TaylorMichaelL





PostPosted: Common Language Runtime, How to set a fixed parameters from SCM? Top

You can't. The parameter field is not stored by the SCM. The parameters you specify in the field are only passed when you then attempt to start the service. They will be lost as soon as the SCM is closed. Instead fixed parameters are set as part of the service's image path when the service is installed.

Michael Taylor - 10/27/06