ThisForm property (WinStudio scripts)
Applies To
IWSForm interface
Definition
Returns a Visual Basic reference to the current form.
Syntax
ThisForm
Remarks
ThisForm is a special, base-level property that references the currently active form. Use this property instead of the FindForm method when you want to reference the current form.
Example
Sub Main
Dim oObject As IWSForm
oObject = ThisForm
' Use methods and properties of Form object
MsgBox( "Form Caption = " + oObject.Caption + vbLf + _
"Form Name = " + ThisForm.Name )
' Use methods and properties of the Form's Component Objects
MsgBox( "Component Value = " + oObject.Components("OutputFormatDescGridCol").Text + vbLf + _
"Component Required = " + ThisForm.Components("OutputFormatDescGridCol").Required.ToString )
End Sub