Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
Objective Views User's Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

9.6 Getting and Setting Property Values

The property container interfaces IPropertyContainer and IODPropertyContainer both provide methods for getting and setting property values. The IPropertyContainer interface provides the GetPropertyValue() and PutPropertyValue() methods to get and set the property values as variants. Since dealing with VARIANTs can be cumbersome, the IODPropertyContainer interface provides a group of GetValue() and SetValue() methods, which are overloaded for several common data types. Either interface is equally valid for accessing property values.

Example 10 uses the IODPropertyContainer interface to disable rotation for a symbol component. Notice that the rotation property is nested in the edit property object and is accessed by combining the base property ID for the edit properties with the property ID for the rotation property.

Example 10: Setting property values

The code segment in Example 11, taken from the CODController class, retrieves the values of two properties using the GetValue() method.

Example 11: Getting property values



Previous fileTop of DocumentContentsNo linkNext file

Copyright © Rogue Wave Software, Inc. All Rights Reserved.

The Rogue Wave name and logo, and Stingray, are registered trademarks of Rogue Wave Software. All other trademarks are the property of their respective owners.
Provide feedback to Rogue Wave about its documentation.