AMEMBERS()

From Lianjapedia
Revision as of 07:13, 4 February 2013 by Helen.george (Talk | contribs)

Jump to: navigation, search

Purpose

Function to load the properties of an object into an array

Syntax

AMEMBERS(<array-name>,<object-ref>])

See Also

ACLASS(), ADDPROPERTY(), COMPOBJ(), CREATEOBJECT(), DEFINE CLASS, DISPLAY CLASSES, DODEFAULT(), FOREACH, LIST CLASSES, LOADOBJECT(), NEWOBJECT(), OBJECT(), PRINT_HTML(), PRINT_JSON(), PRINT_R(), PRINT_XML(), REMOVEPROPERTY(), REQUIRE_ONCE(), SAVEOBJECT(), SQL SELECT, WITH

Description

The AMEMBERS() function is used to load the names of the properties of the specified object into an array and return the number of properties loaded (and hence the number of array elements).

The <array-name> array will be created if it does not already exist.

Example

define class Product as custom
    productname = "Lianja App Builder"
    version = "1.0"
enddefine
 
oProduct = createobject("Product")
 
? amembers(myarray,oProduct)
display memory