Comment on this topic

Documentation Comments

Use this form to comment on this topic. You can also provide any general observations about the Online Documentation, or request that additional information be added in a future release.

Reality V15.2 Online Documentation (MoTW) Revision 3

Access Data in an Object (dbo_access-data_in_object.htm)

To

Reality

Version

Topic

Submitted by

Company

Location

Email address

Comment

 

 

Access Data in an Object

Data is held in an object within fields. Depending on the object definition, this data may be directly accessible using the -> operator.

Assignment syntax

Object -> field = expression

Expression syntax

Object -> field

Syntax elements

Object DBO variable name.
field The object field name being accessed.
-> The object operator.
expression Any DataBasic expression that produces a result suitable to be assigned to field.

Comments

As Object -> field is itself an expression, it can be used in place of a single element within a DataBasic statement.

Examples

Font -> Style = "bold"

Set the Style field in the Font object to the string "bold".

Var = Object -> Field

Extract the Field element from Object and save it in Var.

CALL SUBROUTINE( Object -> Field, P2)

Extract the Field element from Object and pass it as first parameter of the call to the subroutine SUBROUTINE.

A = B + Object -> Field * Object -> Field

Use the content of the Field element in an arithmetic expression.

A = Object -> Field -> Field2

Extract the contents of Field2 from the field Field in the object Object.

RealityV15.2Revision 3Comment on this topic