Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
vvv vvv is offline
external usenet poster
 
Posts: 2
Default how to create a zoom butom in vba excel

hey guys how do I create a button (vba code) that upon each click changes the
zoom of the workshet?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8,520
Default how to create a zoom butom in vba excel

You can. Try
'to zoom out
ActiveWindow.Zoom = (ActiveWindow.Zoom-10)

to zoom in
ActiveWindow.Zoom = (ActiveWindow.Zoom+10)

If this post helps click Yes
---------------
Jacob Skaria


"vvv" wrote:

hey guys how do I create a button (vba code) that upon each click changes the
zoom of the workshet?

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default how to create a zoom butom in vba excel

You could record a macro to get the syntax and modify that recorded macro to do
what you want.

Then you could place a button from the Forms toolbar on the sheet and assign
this macro to the button.

But an alternative would be to add a couple of buttons to your favorite toolbar
(xl2003 and earlier).

In xl2003 menus:
Tools|Customize|Commands tab|View Category
Scroll down in the commands listbox until you see:
Zoom In
and drag it to your favorite toolbar
Do the same with Zoom out

I don't know if the same icons are available in xl2007 so that you can add them
to the QAT.

By putting these icons on your favorite toolbar (or QAT if available), you'll
have this functionality in all worksheets.


vvv wrote:

hey guys how do I create a button (vba code) that upon each click changes the
zoom of the workshet?


--

Dave Peterson
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
how to create a zoom butom in vba excel vvv Excel Programming 1 October 8th 09 07:10 AM
Please help! Print Preview Zoom is Grayed Out...Doesn't zoom. PK Excel Discussion (Misc queries) 0 July 20th 09 03:33 PM
Zoom in/Zoom out picture [email protected] Excel Programming 1 January 27th 08 04:19 PM
zoom in &zoom out in VBA User Form [email protected] Excel Programming 0 January 21st 08 04:59 AM
zoom in Excel Eric Excel Discussion (Misc queries) 0 June 1st 05 12:13 AM


All times are GMT +1. The time now is 04:33 PM.

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

About Us

"It's about Microsoft Excel"