In the UI, you can arrange the open windows using Windows>Arrange. In VBA, the same effect is achieved using the Arrange method of the Windows collection object.
The argument is an xlArrangeStyle constant. What I haven’t been able to do is determine the current state of the windows. That is, there’s no ArrangeStyle property to read.
To cycle through some different arrangements, you can store the current ArrangeStyle in a variable and use that variable to switch to another style. In this example, the windows are cycled through normal maximized view, tiled arrangement, and horizontal arrangement.
‘Cycle through Maximized, Tiled, and Horizontal
Select Case mlWndState
mlWndState = xlArrangeStyleTiled
mlWndState = xlArrangeStyleHorizontal
Application.ActiveWindow.WindowState = xlMaximized
mlWndState = xlMaximized