Height property (WinStudio scripts)

Applies To

  • IWSForm interface
  • IWSFormComponent interface

Definition

Form objects: Sets or returns the height of a form in character units. Read/write.

Component objects: Returns the height of a component in character units. Read-only.

Get Syntax

object.Height

  Part   Description
object Required. A reference to a form or component object.

Set Syntax

object.Height = double

  Part   Description
object Required. A reference to a form or component object.
double Required. Form objects only. An expression that evaluates to type Double and sets the height of the form using character units. The value must be greater than 0.

Remarks

The return value is type Double and indicates the form or component height in character units.

Examples

For a form:

Sub Main()
    Application.ShowMessage("The current height of this form = " & _
       ThisForm.Height & " units.")
    ThisForm.Height = 35
    Application.ShowMessage("The height of this form now = " & _
       ThisForm.Height & " units.")
End Sub

For a component:

Sub Main()
   'Find the height of a component on another form. 
   Dim activeComponent As String
   Dim actCompProperty As String
         
   activeComponent = Application.FindForm("EventActions"). _
      GetCurrentComponentName()
   actCompProperty = Application.FindForm("EventActions"). _
      Components(activeComponent).Height.ToString()
   Application.ShowMessage("The height of " & activeComponent & " is " _
      & actCompProperty & " character units.")
End Sug