system.mes.getMaterialLotNextAvailable

Sepasoft MES Module Suite

system.mes.getMaterialLotNextAvailable(responseSegment, materialPropertyName, lotNamePattern)

Get a link the next available material lot object for the specified segment and material property. If there is no available material lot None is returned.

Warning

Segment that is passed must be running before calling this function. (See example below).

Syntax

system.mes.getMaterialLotNextAvailable(responseSegment, materialPropertyName, lotNamePattern)

  • Parameters

MESResponseSegment responseSegment - The MES object used when determining the next available lot. Segment that is passed must be running before calling the function.

String materialPropertyName - The name of the material property to get next available lot.

String lotNamePatternThis is a pattern to filter the lot names according to when determining the next available lot.

  • Returns

A MES Object Link object representing to the next available lot. If there is no available material lot None is returned.

  • Scope

All

Python
segment = system.mes.createSegment('Your Operations Segment Name','line/that/you/are/running/on', True)

segment = segment.begin()

next_material_lot =  system.mes.getMaterialLotNextAvailable(segment, 'Mat Prop Name', 'Search Pattern')
print next_material_lot

segment = segment.end()

Output

Code
ResponseSegment (7b3ee6b7-3835-4863-aa14-d539637374f3, Your Operations Segment Name, 0 parents, 0 children, 0 custom properties, 7 complex properties)

Sepasoft MES Module Suite