SetWindowRect method

Microsoft Visio Developer Reference

SetWindowRect method

   Example   

Sets the size and position of the client area of a window.

Version added

2000

Syntax

object.SetWindowRect nLeft, nTop, nWidth, nHeight

object

Required. An expression that returns a Window object.

nLeft

Required Long. The coordinate of the left side of the window.

nTop

Required Long. The coordinate of the top of the window.

nWidth

Required Long. The distance in pixels from the left side to the right side of the window.

nHeight

Required Long. The distance in pixels from the top to the bottom of the window.

Remarks

The SetWindowRect method sets the size and position of the client area of the window with respect to the window that owns the Windows collection to which it belongs. For the Windows collection of an Application object, the "with respect to" window is the MDICLIENT window of the Visio main window. For the Windows collection of a Window object, the "with respect to" window is the client area of the drawing window.