Skip to content

GET_MODELGROUP_REFERENCE_THREAD ​

GET_MODELGROUP_REFERENCE_THREAD returns the id of the modelthread to which the modelgroup reference points.

Syntax ​

leo-grammar
CC "Core" GET_MODELGROUP_REFERENCE_THREAD refid:intValue

#--> RESULT ecode:intValue  threadid:intValue .

Parameters ​

  • refid (intValue) - the id of the modelgroup reference

Returns ​

  • ecode (intValue) - Contains the error code or is 0 in case of success.
  • threadid (intValue) - the id of the referenced model thread.

Details ​

See Also ​

Examples ​

Creating a new modelgroup reference

leo-grammar
# let the user select a modelgroup
CC "CoreUI" MODEL_SELECT_BOX without-models mgroup-sel
SET mgroup:(VAL token(mgroupids,0," "))

# let the user select a modelthread
CC "CoreUI" MODEL_SELECT_BOX threads
SET mthread:(VAL token (threadids,0," "))

# create a new reference
CC "Core" CREATE_MGROUP_REFERENCE mgroupid:(mgroup) threadid:(mthread)
SET mref:(refid)

CC "Core" GET_MODELGROUP_REFERENCE_THREAD refid:(mref)

CC "AdoScript" INFOBOX ("Thread: " + STR threadid)

Versions and Changes ​

Available since ADOxx 1.3