NewBoundedObjectArray

PowerBuilder Native Interface

IPB_Session interface:

NewBoundedObjectArray method

Description

Syntax

NewBoundedObjectArray(pbclass cls, pbuint dimension, PBArrayInfo::ArrayBound* bounds)

Return Values

Examples

int size;
pbarray pbin_a;
PBArrayInfo* ai;
PBXRESULT ret;
pbclass cls;
pbgroup group;

size = sizeof(PBArrayInfo) +
   sizeof(PBArrayInfo::ArrayBound);
ai = (PBArrayInfo*)malloc(size);
ai-> bounds[0].upperBound=2;
ai-> bounds[0].lowerBound=1;
ai-> bounds[1].upperBound=2;
ai-> bounds[1].lowerBound=1;
ai-> numDimensions=2;

// Create new array pbin_a
group = session-> FindGroup("w_main", pbgroup_window);
if (group==NULL)
   return;
cls = session->FindClass(group, "commandbutton");
if( cls==NULL)
   return;
pbin_a = session->NewBoundedObjectArray(cls,
   ai-> numDimensions, ai-> bounds);

See Also