I have a few people experiencing an issue in my program in which people are reporting a program exception/crash when the program attempts to execute the RegisterTaskDefinition() function.
The following is my code...
The following is my code...
Dim taskService As New TaskService
' Where all of my task setup code is. It's too long to mention here so I won't.
taskService.RootFolder.RegisterTaskDefinition("System Restore Checkpoint by System Restore Point Creator", newTask, TaskCreation.CreateOrUpdate, "NT AUTHORITY\System", vbNullString, TaskLogonType.InteractiveToken, vbNullString)
How is the RegisterTaskDefinition() causing an exception on the RootFolder in the Task Scheduler? The RootFolder should always exist so I shouldn't have a problem with this code yet it has some issues on some people's computers. What's going on here?