PrependDynamicObject - cWebDynamicObjectContainer
Prepends a dynamic object to its parent's list of children
Type: Procedure
Parameters
| Parameter | Type | Description |
|---|---|---|
| sDynamicObjectId | String | Object to prepend |
Syntax
Procedure PrependDynamicObject String sDynamicObjectId
Call Example
Send PrependDynamicObject sDynamicObjectId
Description
Prepends a dynamic object to the beginning of its parent's list of children removing previously appended object from the list.
Sample
This sample creates dynamic object oGroup2 with one child object (oForm), creates a second dynamic object (oForm1) and then prepends oForm1, making it the first child object (index 0) of oGroup2.
Get CreateDynamicObject of oContainer (RefClass(cWebGroup)) "oGroup2" "" to hoGroup2
Send InitDynamicProp of hoGroup2 "piColumnCount" 8
Get CreateDynamicObject of oContainer (RefClass(cWebForm)) "oForm" "oGroup2" to hoForm
Send InitDynamicProp of hoForm "piColumnSpan" 8
Send InitDynamicProp of hoForm "psLabel" "My form"
Get CreateDynamicObject of oContainer (RefClass(cWebForm)) "oForm1" "oGroup2" to hoForm1
Send InitDynamicProp of hoForm1 "piColumnSpan" 8
Send InitDynamicProp of hoForm1 "psLabel" "My form1"
Send PrependDynamicObject of oContainer "oForm1"