MoveDynamicObject - cWebDynamicObjectContainer
Moves a dynamic object inside its container
Type: Procedure
Parameters
| Parameter | Type | Description |
|---|---|---|
| sDynamicObjectId | String | Dynamic object to move |
| sInsertAfter | String | Object to move sDynamicObjectId after |
Syntax
Procedure MoveDynamicObject String sDynamicObjectId String sInsertAfter
Call Example
Send MoveDynamicObject sDynamicObjectId sInsertAfter
Description
Moves a dynamic object inside its container. This requires the object that is being moved to already exist inside the container. Furthermore, the moved object inherits the parent structure of the object it is moved after.
Sample
This sample creates dynamic object oGroup2 with three child objects (oForm1, oForm, oForm2) and then moves oForm2 to after oForm1.
Get CreateDynamicObject of oContainer (RefClass(cWebGroup)) "oGroup2" "" to hoGroup2
Send InitDynamicProp of hoGroup2 "piColumnCount" 8
Get CreateDynamicObject of oContainer (RefClass(cWebForm)) "oForm1" "oGroup2" to hoForm1
Send InitDynamicProp of hoForm1 "piColumnSpan" 8
Send InitDynamicProp of hoForm1 "psLabel" "My form1"
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)) "oForm2" "oGroup2" to hoForm2
Send InitDynamicProp of hoForm2 "piColumnSpan" 8
Send InitDynamicProp of hoForm2 "psLabel" "My form2"
Send MoveDynamicObject of oContainer "oForm2" "oForm1"