This function returns the parent form of the specified label control.
object.GetParentForm(
[aFormTypeName])
Part | Attribute | Type | Description |
---|---|---|---|
object |
Required | The object always implements the
ISLabel interface |
|
aFormTypeName |
Optional | string |
The name of the form type |
Display the short name of the form for the control and some information of all parent controls in the hierarchical tree starting from the specified label control.
sub main()
Dim aLabel
Dim aLabelInfo
Dim aForm
Set aLabel = Form.Controls_("Label1")
set aForm = aLabel.GetParentForm("TIVisualForm")
aLabelInfo = "Form: " & aForm.ShortName & vbNewLine & vbNewLine
do while not aLabel is nothing
aLabelInfo = aLabelInfo &_
"ShortName: " & aLabel.ShortName & vbNewLine &_
"TypeName: " & aLabel.TypeName & vbNewLine &_
"---------" & vbNewLine
set aLabel = aLabel.Parent
loop
Profile.MsgBox(aLabelInfo)
end sub
In Profile Client v8 on User Interface Parent Form can be found in
.