Page 1 of 1

Setting service options in code.

Posted: Mon Dec 14, 2020 4:03 pm
by Raoul
Hi,

I looked at this post to enable NT Service settings for my service:
viewtopic.php?f=4&t=5237

However, I am using a combo Service/App application, it starts as an app with a parameter.

How can I make these settings in code?

Thansk

Re: Setting service options in code.

Posted: Tue Dec 15, 2020 1:29 pm
by madshi
Here is the documentation:

http://help.madshi.net/MESettings.htm

Basically in your code you can do (e.g. in your project initialization) do things like:

Code: Select all

with MESettings() do
begin
  SomeSetting := 'new value';
  SomeOtherSetting := 777;
end;
To be more specific, for service you probably want to change "GeneralShowSetting := ssNothing" and "AutoSave := true".