Table of contents
Collapse the table of content
Expand the table of content

Window.Height Property (Project)

office 365 dev account|Last Updated: 6/12/2017
1 Contributor

Gets or sets the height of a project window in points. Read/write Long.


expression. Height

expression A variable that represents a Window object.


A window changes its height by moving its bottom edge, leaving the top edge unaffected.


The following example places the main window in the lower half of the screen.

Sub PlaceProjectInLowerScreenHalf() 

 Dim WindowWidth As Double 

 Application.WindowState = pjMaximized 
 WindowWidth = Application.Width 'Remember the width when maximized. 

 Application.Height = Application.Height / 2 
 Application.Top = Application.Height 

 'Ensure that the window uses all the available width. 
 If Application.Width < WindowWidth Then 
 Application.Width = WindowWidth 
 Application.Left = 0 
 End If 

End Sub
© 2018 Microsoft