DIAdem Help

Property: Definition for Assignment <Data>

  • Updated2024-09-12
  • 1 minute(s) read

Property: Definition for Assignment <Data>

Specifies the numeric value of an assignment, in the script interface for internal data. A text value (property Value) is assigned to a numeric value (property Definition) or a value range (property DefinitionRange) in order to define an assignment.

Object.Definition
ObjectAssignment <Data>
Object with this property
Object.DefinitionVariant with read and write access

The following example generates an assignment channel with three assignments and displays these assignments:

VBScriptPython

 

Dim oMyGrp, oMyChn, oMyAssgnList, Assignment
Set oMyGrp = Data.Root.ChannelGroups(1)
Set oMyChn = oMyGrp.Channels.AddAssignmentChannel("MyAssignmentChn","Default Value")
Set oMyAssgnList = oMyChn.AssignmentList
Call oMyAssgnList.Add("text1",1)
Call oMyAssgnList.Add("text2",2)
Call oMyAssgnList.Add("text3",3)
For Each Assignment in oMyAssgnList
  Call MsgBoxDisp("Definition Value: " & Assignment.Definition & vbCrLf & "Text: " & Assignment.Value)
Next

Log in to get a better experience