Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default How to change windows.arrange from xlTiled to xlHorizontal and back in one procedure

I want to create one button, which changes arranging the windows on
the screen from maximized status to tiled, by next clicking from tiled
to horizontal, by next clicking from horizontal back to maximized.
I don't know, how to get ArrangeStyle value to set the next one in one
procedure.
Thank you
Zdenek Moravec
Panasonic AVC Networks Czech
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 595
Default How to change windows.arrange from xlTiled to xlHorizontal and back in one procedure

Zdenek

I don't either. You'd think that would be a property of Application or
Windows, but I sure can't find it. You could use a module level variable as
a workaround.

Dim lWndState As Long

Sub SwitchView()

Select Case lWndState
Case xlMaximized
Windows.Arrange xlArrangeStyleTiled
lWndState = xlArrangeStyleTiled
Case xlArrangeStyleTiled
Windows.Arrange xlArrangeStyleHorizontal
lWndState = xlArrangeStyleHorizontal
Case Else
ActiveWindow.WindowState = xlMaximized
lWndState = xlMaximized
End Select

End Sub

--
Dick Kusleika
Excel MVP
Daily Dose of Excel
www.dicks-blog.com

Zdenek Moravec wrote:
I want to create one button, which changes arranging the windows on
the screen from maximized status to tiled, by next clicking from tiled
to horizontal, by next clicking from horizontal back to maximized.
I don't know, how to get ArrangeStyle value to set the next one in one
procedure.
Thank you
Zdenek Moravec
Panasonic AVC Networks Czech



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default How to change windows.arrange from xlTiled to xlHorizontal and back in one procedure

Hello Dick
This is exactly, what I need.
Thank you
Zdenek Moravec

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Grouped Sheets - Windows Arrange JMay Excel Discussion (Misc queries) 8 November 15th 06 12:53 AM
Arrange Windows Bean123r Excel Discussion (Misc queries) 0 January 24th 06 09:35 PM
Excel should let me change the form data arrange direction Andy Excel Worksheet Functions 0 November 2nd 05 05:37 AM
change event procedure benb Excel Programming 2 September 24th 04 09:22 PM
Worksheet change sub procedure Grant Excel Programming 5 September 24th 04 01:44 AM


All times are GMT +1. The time now is 06:13 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"