I'm doing some tests with the following code which creates a task to run Notepad after 2 minutes. It works on Windows 8.1 and Windows 10 but with Windows 10 Creators update the task does not run. It just moves on to the next date and if task history is turned on nothing is recorded in the history.
using (TaskService ts = new TaskService())
{
string name = "AJC test " + Guid.NewGuid();
// Create a new task definition and assign properties
TaskDefinition td = ts.NewTask();
td.RegistrationInfo.Description = name;
// Create a trigger that will fire the task in 2 minutes time
Trigger Trigger = new DailyTrigger();
Trigger.StartBoundary = DateTime.Now.AddMinutes(2);
td.Triggers.Add(Trigger);
// Create an action that will launch Notepad whenever the trigger fires
td.Actions.Add(new ExecAction("notepad.exe", @"c:\tmp\abc.txt", null));
// Register the task in the root folder
ts.RootFolder.RegisterTaskDefinition(name, td);
}