vision_object.Status Property

Gets the numeric status code for a vision process.

...vision_object.Status

Prerequisites

None

Parameters

None

Remarks

This method returns the status code for the vision process associated with the vision_object. Table 23-110 shows the returned status codes.

Table 23-110: Status Property

Status Code Description

0

No vision process for this object

1

Vision process is running

2

Vision process completed but with error

3

Vision process completed with success

At this time, the value 1 is not seen because the Process method always waits until the vision process is complete. A no-wait vision process may be added as a future enhancement.

If Status has a value is 2, the ErrorCode property can be used to determine the specific type of error that has occurred.  Note, this property returns an error if the process did not exist or if a communication error occurs.  However, if a specific tool fails, such as when a Line Fitter cannot find enough edges to fit a line, Status does not indicate an error.  For tool analysis errors, please see the visresults_object.ErrorCode property.

Examples

Dim vobject As New Vision
vobject.Process("find_part")
If vobject.Status <> 3 Then
' Handle non-successful process
End If

See Also

Vision Classes |vision_object.ErrorCode | visresults_object.ErrorCode