Previous Document Next Document

Object Model Reference : Classes : S : Shape : Properties : Shape.ObjectData


Shape.ObjectData

Property ObjectData As DataItems

Description

Member of Shape

The ObjectData property returns a DataItems collection, which represents the object data associated with a shape.

 
Object data can also be manipulated through the Object Data Manager in CorelDRAW.

The ObjectData property returns a read-only value.

VBA example

The following VBA example creates a new data field and sets it to the area of a shape for each shape encountered on the active page.

Sub Test()
 Dim s As Shape, x As Double, y As Double
 ActiveDocument.DataFields.Add "Area", "0.000"
 For Each s In ActivePage.Shapes
  s.GetSize x, y
  s.ObjectData("Area").Value = x * y
 Next s
End Sub

Previous Document Next Document Back to Top

Copyright 2013 Corel Corporation. All rights reserved.