This stumped me for an hour when I deployed a new version of the application to be called by an existing scheduled task. However, the task kept failing to launch, with a ResultCode 2147942402.
Google search didn’t yield anything useful.
It turns out the error is caused by the simple fact that the application has changed and it needs to be updated in the scheduled task’s Action properties.
So the lesson learned here is to try recreate a scheduled task when you get this error.