Site icon EfmSoft

What does HRESULT 0x00041303 (SCHED_S_TASK_HAS_NOT_RUN) mean?

 
Previous Next
SCHED_S_TASK_DISABLED SCHED_S_TASK_NO_MORE_RUNS

SCHED_S_TASK_HAS_NOT_RUN

Scheduled task has no completed run history

SCHED_S_TASK_HAS_NOT_RUN is HRESULT 267011 (0x00041303) from winerror.h. The documented description is “The task has not yet run.” The severity bit indicates a nonfailure result, but the value carries a specific condition that must not be collapsed into plain S_OK.

In the Task Scheduler state query, this result means that the task has not yet run. Before reporting completion, the caller must reconcile the code-specific state transition and every usable output.

What must be true before accepting it

Verify that the absence of a prior run is explained by creation time, trigger eligibility, or history retention instead of being reported as an execution failure. Without that proof, this result can mask a caller error even though HRESULT failure severity is not set.

Reconcile side effects associated with this result before compensation or a second invocation is attempted.

Where the status is encountered

  • This result can be returned during Task Scheduler status monitoring; log the exact method and object state instead of interpreting the constant outside that contract.
  • It can be returned during deployment or maintenance task validation; log the exact method and object state instead of interpreting the constant outside that contract.
  • It can be returned during automation that reads task state before starting work; log the exact method and object state instead of interpreting the constant outside that contract.

Evidence to preserve

  • Preserve registration timestamp.
  • Preserve first eligible trigger time.
  • Preserve start-when-available setting.
  • Preserve service uptime.
  • Preserve history retention and last-run fields.

Correct handling and recovery

Compare task registration time with trigger boundaries and service uptime. If a run should already have occurred, inspect missed-start policy, credentials, conditions, and Task Scheduler operational events.

Practical scenario

A newly deployed weekly task returns this status on the same day it was registered. Monitoring suppresses the failure alarm until the first eligible trigger, while retaining a deadline for the expected first run.

Difference from nearby results

SCHED_S_TASK_READYIt

Correctly separating it from neighboring values selects the proper continuation and cleanup path.

References


Looking for a different code? Search another status or error code.

Exit mobile version