Previous Document Next Document
DataItem.DataField

Property DataField As DataField

Member of DataItem

The DataField property returns the corresponding DataField to which the given DataItem belongs.

The DataField property returns a read-only value.

The following code example shows a list of all object data items assigned to the selected shape. Each text line in the message box lists the field name and its value as they appear in Object Data Manager docker.

Sub Test() 
 Dim di As DataItem 
 Dim s As String 
 s = "Field = Value" & vbCr 
 For Each di In ActiveShape.ObjectData 
  s = s & vbCr & di.DataField.Name & " = " & di.FormattedValue 
 Next di 
 MsgBox s 
End Sub 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.