GetPossibleLegalUnits

The
GETPOSSIBLELEGALUNITS
execute retrieves the possible binding options for a non-statically bound unit procedure or operation.
The format and return for this execute includes:
Execute Format
A
FactoryTalk Batch
Server supports an execute with this format:
[GETPOSSIBLELEGALUNITS(
Item, UserID,CreateID \t UnitProcName
)]
where:
Item
Name of the response item as specified by the client.
UserID
User Identification entered into the event journal associated with this event.
CreateID
Unique ID, as assigned by the system, of the procedure which contains the step which requires binding
UnitProcName
Path to a step representing a Unit Procedure inside of a Batch Procedure.
<Path>
where:
<Path>
is
<CreateID>
/t
<StepIdentifier>
where:
Field
Format
Description
<CreateID>
ASCII - Integer
Unique batch ID assigned by the
FactoryTalk Batch
Server.
<StepIdentifier>
ASCII – String
Step identifier (for example, Mix:1)
Action
A successful GETPOSSIBLELEGALUNITS execute returns the alias name along with a list of IDs and names of the possible binding units or binding options for the specified Unit Procedure or Operation.
Return Format
The response item populates with this data:
SUCCESS:[
<Units>
] | FAIL:<message> | FAILED
<Units>
is
<UnitAlias>,<UnitList>
<UnitList>
is
<Unit>
|
<Unit>,<UnitList>
<Unit>
is
<UnitName>,<UnitID>
where:
Field Name
Format
Description
<UnitAlias>
ASCII - String
Alias associated with the specified Unit Procedure.
<UnitName>
ASCII - String
Name of a Unit that can be a legal bind target for the Unit Procedure, or a legal binding option (Prompt or First Available)
<UnitID>
ASCII - String
Unit ID associated with the unit name. The legal binding options have this associated Unit ID:
  • Prompt = -1
  • First Available = -2
The following table shows an example of the return on this execute.
Example:
An execute string consisting of:
GETPOSSIBLELEGALUNITS(Item,Station2/View,36 \t ADDCREAM_UP:1)
Could return:
SUCCESS:MIXER,NP_MIXER1,55,NP_MIXER2,84,PROMPT,-1,FIRST AVAILABLE,-2
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal