I'm trying to run a task when I get a network connection and am following these steps.
I created a test.bat that does some stuff script that and set the task scheduler trigger for it to Log: Microsoft-Windows-NetworkProfile/Operational
Source: NetworkProfile
Event ID: 10001
(just on disconnect for now).
When I disconnect from my wifi, in the Event Viewer I can see under Event Viewer->Application and Services Logs->Microsoft->->Windows->NetworkProfile->Operational that the event with ID 10001 is created. However, my bat script is never run.
When I run the task manually or schedule it at a certain time, everything works just fine.
Best Answer
Found the solution: For some reason, the trigger was set as
When I created a new task (I'm so sure I followed the same steps to a T!), the trigger was listed as
which worked. (No idea what I did wrong the first time).