Skip to end of metadata
Go to start of metadata
Description

Get the currently executing response segments for the specified equipment. This function only returns segments for the most recent operation if multiple operations are running.

When multiple operations are running on a piece of equipment, this function will only return segments for the most recent operation. Use system.mes.getCurrentOperations() function to return a list of active operations and then call the ops.getActiveSegmentNames() object method to return a list of active segments instead of this function.

Example
ops = system.mes.getCurrentOperations('[global]\Enterprise\Site\Area\Line 3')
for op in ops:
	print op
	for segName in op.getActiveSegmentNames():
		seg = op.getActiveSegment(segName)
		print seg
Syntax

system.mes.getCurrentSegments(equipmentPath)

 

  • Parameters

 String equipmentPath - The path of the equipment to return the currently executing response segments.

  • Returns

A list of the currently executing response segments for the equipment specified by the equipmentPath parameter. The list is returned as a MESList object that is a collection holding MESObjectLinks for each segment object.

  • Scope

All

Code Examples
Code Snippet
#This example will return the currently executing segments
segCurrent = system.mes.getCurrentSegments('Dressings Inc\California\Raw Materials\Unload Station 1')
  • No labels