Results 1 to 6 of 6

Zoom on workbook open

Threaded View

Adrian692 Zoom on workbook open 06-02-2013, 09:45 AM
HaHoBe Re: Zoom on workbook open 06-02-2013, 09:58 AM
AlvaroSiza Re: Zoom on workbook open 06-02-2013, 11:41 AM
Adrian692 Re: Zoom on workbook open 06-02-2013, 01:25 PM
HaHoBe Re: Zoom on workbook open 06-02-2013, 01:42 PM
Adrian692 Re: Zoom on workbook open 06-05-2013, 04:21 PM
  1. #1
    Registered User
    Join Date
    05-31-2013
    Location
    Bruges
    MS-Off Ver
    Excel 2010
    Posts
    7

    Question Zoom on workbook open

    Hello

    I would like to zoom on a specific sheet (not the other sheets).
    I put this code in "This workbook" :
    Private Sub Workbook_Open()
        Worksheets("SheetName").Columns("A:L").Select
        ActiveWindow.Zoom = True
        Range("A1").Select
    End Sub
    This works when the sheet opened when I open the excel file is SheetName but whent an other sheet is opened when I opent my file I have a bug.

    So I write this :
    Private Sub Workbook_Open()
        Worksheets("SheetName").Activate
    Columns("A:L").Select
        ActiveWindow.Zoom = True
        Range("A1").Select
    End Sub
    It seems to work but I think there is a much better way to do that !
    I don't like the "Activate" and the "Select" but don't know how to avoid them.
    Could you help me please ?
    Last edited by Adrian692; 06-05-2013 at 04:21 PM.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1