Partager via


GetDockState Method

Returns information in an array about the dock state of a form.

Note

To use GetDockState, the form's Dockable property must be set to 1.

Form.GetDockState(ArrayName)

Parameters

  • ArrayName
    Returns a single row, six-column array containing dock information for a form.

    Note

    You must first create the array before passing an array name.

    The following table describes the array returned by GetDockState.

    Column

    Description

    1

    Name of the docking form.

    2

    Dock state:

    1 - Docked

    2 - Not docked

    3

    Dock position.

    For values, see DockPosition Property.

    4

    Target form, or caption of the form to which the specified form is docked.

    5

    Object reference for the docking form.

    6

    Object reference for the target window or form.

Return Value

Applies To: Form Object

Logical data type. GetDockState returns True (.T.) if the array is successfully updated with the dock state. Otherwise, GetDockState returns False. (.F.).

Remarks

If a form is docked to an IDE window, the value of column 6 will be an empty string. If a form is docked to the Visual FoxPro desktop, then column 6 will contain an object reference to _SCREEN.

GetDockState is a limited variation of the ADOCKSTATE( ) function in that it limits its details to the current form. Since GetDockState is a limited subset of the ADOCKSTATE( ) function, it may not provide all the necessary information about the current docking state of the form. You may need to call ADOCKSTATE( ) as well to obtain more complete picture. For more information, see ADOCKSTATE( ) Function.

See Also

Tasks

How to: Dock Forms

Reference

Dock Method

GetDockState Method

Dockable Property

Docked Property

DockPosition Property

AfterDock Event

BeforeDock Event

UnDock Event

Other Resources

Methods (Visual FoxPro)