Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AVEVA™ Manufacturing Execution System 2023 R2

EndJob() method

  • Last UpdatedNov 26, 2024
  • 2 minute read

Use the EndJob() method to end the specified job if the following conditions exist:

  • The job is in a running or in a suspended state.

  • The operator is authorized to end jobs.

  • The required quantity for the job has been met.

Syntax

EndJob(woId,operId,seqNo,woDesc,jobDesc,statusNotes,canAppendNotes,
canReplaceNotes,qtyGood,qtyRejected,qtyStart,qtyReqd,selJobState,
userCancelled[,concurrentLink]);

Parameters

woID

A string that indicates the work order ID of the job to be ended.

operID

A string that indicates the operation ID of the job to be ended.

seqNo

An integer that represents the sequence number of the job to be ended.

woDesc

A string that indicates the work order description used in the confirmation dialog box.

jobDesc

A string that indicates the Job description used in the confirmation dialog box.

statusNotes

A string that holds the status notes of the job that are shown in the confirmation dialog. These notes can be appended to or edited on this dialog if the operator has the privileges to do so.

canAppendNotes

A Boolean value that is True if this operator can append to the Status Notes in the confirmation dialog box.

canReplaceNotes

A Boolean value that is True if this operator can replace the Status Notes in the confirmation dialog box.

qtyGood

A double data type value that indicates the total produced quantity for this job that are good.

qtyRejected

A double data type value that indicates the total produced quantity for this job that are rejected.

qtyStart

A double data type value that indicates the start quantity for this job. The quantity produced can not be less then this amount when ending the job.

qtyReqd

A double data type value that indicates the total required quantity for this job. This quantity must be met in order to end the job.

selJobState

An enumeration data type that indicates the state of the job selected to be ended. The enumerated data type can have the following values:

  • NoJob (A value to set a current job state property to JobStates, if no job is running)= -1

  • New (A job that is scheduled but not yet ready to run) = 1

  • Ready ( A job that is ready to run) = 2

  • Running (A job that is currently running on an entity) = 3

  • Complete (A job that has finished) = 4

  • Suspended (A job that has not run to completion, but is no longer running on an entity) = 5

  • Onhold (A job that is no longer ready to run) = 6

  • Cancelled (A job that no longer needs to be run) = 7

userCancelled

A Boolean value that is returned as True if the operator cancels this action when prompted for confirmation.

concurrentLink

An integer value for the specified job that is used to determine if this is a batch of jobs or not. If this value is greater than zero and other jobs in the queue contain the same value, then this job is a part of a batch. This is an optional parameter and the default value is 0.

In This Topic
TitleResults for “How to create a CRG?”Also Available in