I like to make task triggered by service state (Running) to stop the service. stopping part is fixed and working with scheduled task triggered 3min after system start up to run batch file:
@echo off
sc stop "wuauserv"
sc config "wuauserv" start= disabled
so everything to this point works, but I noticed that service is started by something again, so I tried looking for how to setup a trigger by service state Running, and I found here that it is possible to trigger On Event > setting > custom > XML. I added the code as second triger, but XML does not seemd to do anything. maybe my code is wrong? the code:
<QueryList>
<Query Id="0" Path="System">
<Select Path="System">
*[EventData[Data[@Name='param1'] and (Data='Windows Update')]]
and
*[EventData[Data[@Name='param2'] and (Data='Running')]]
</Select>
</Query>
</QueryList>
XML is not working and for XML part I need help with
I also tried wuauserv instead of Windows update, also running and Running. system language ENG, Win10 Pro 22H2