<p dir="ltr">That works great thanks :)</p>
<div class="gmail_quote">On 4 Feb 2016 22:53, "Jy V" <<a href="mailto:jyv110@gmail.com">jyv110@gmail.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Feb 4, 2016 at 8:57 PM, Richard Mace <span dir="ltr"><<a href="mailto:richard.mace@gmail.com" target="_blank">richard.mace@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><span><div style="font-family:arial,helvetica,sans-serif"><span style="font-family:arial,sans-serif">On 4 February 2016 at 17:39, Jy V </span><span dir="ltr" style="font-family:arial,sans-serif"><<a href="mailto:jyv110@gmail.com" target="_blank">jyv110@gmail.com</a>></span><span style="font-family:arial,sans-serif"> wrote:</span><br></div></span><div class="gmail_extra"><div class="gmail_quote"><span><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span>On Thu, Feb 4, 2016 at 5:41 PM, Richard Mace <span dir="ltr"><<a href="mailto:richard.mace@gmail.com" target="_blank">richard.mace@gmail.com</a>></span> wrote:<br></span><div>XMLRAD stop a program registered as a service running following code,<br></div><div></div></div></div></div></blockquote><div><br></div></span><div><div style="font-family:arial,helvetica,sans-serif;display:inline">​So, would I run this code by creating a TProcess from within my service, to get it to "stop" my service?</div></div></div></div></div></blockquote><div><br></div><div>if you have the SvcHandle available inside your program since you are the very own running service,<br>you can even skip OpenSCManagerA and OpenServiceA and stop the process directly<br></div><div>calling ControlService(SvcHandle, SERVICE_CONTROL_STOP, Status)</div></div></div></div>
<br>--<br>
_______________________________________________<br>
Lazarus mailing list<br>
<a href="mailto:Lazarus@lists.lazarus.freepascal.org">Lazarus@lists.lazarus.freepascal.org</a><br>
<a href="http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus" rel="noreferrer" target="_blank">http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus</a><br>
<br></blockquote></div>