+ Reply to Thread
Results 1 to 6 of 6

Set Excel to look the same on all monitor resolutions

Hybrid View

AndyMan81 Set Excel to look the same on... 07-17-2014, 08:49 AM
Olly Re: Set Excel to look the... 07-17-2014, 09:09 AM
AndyMan81 Re: Set Excel to look the... 07-17-2014, 09:19 AM
Olly Re: Set Excel to look the... 07-17-2014, 09:36 AM
AndyMan81 Re: Set Excel to look the... 07-17-2014, 09:40 AM
Olly Re: Set Excel to look the... 07-17-2014, 09:57 AM
  1. #1
    Registered User
    Join Date
    10-10-2013
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    49

    Set Excel to look the same on all monitor resolutions

    Hi all,

    Ok, I have finally finished my Excel project, however the challenge I now face is to make the Excel document look the same on all monitors.

    For example, I have a laptop that I doc when I am in the office. When I view the file when the laptop is doc'd (on monitors), the file looks perfect. However when I view the file on my acutal laptop screen I need to play around with the zoom to allow the file to fit properly.

    Has anyone got a VBA code I can use?

    I need to show columns A to Y, and rows 1 to 32.

    Many thanks,

    Andy.

  2. #2
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Set Excel to look the same on all monitor resolutions

    Try:
    Sub zoomfoo()
    Dim c As Range
    Set c = Selection
    Range("A1:Y32").Select
    ActiveWindow.Zoom = True
    c.Select
    End Sub
    let Source = #table({"Question","Thread", "User"},{{"Answered","Mark Solved", "Add Reputation"}}) in Source

    If I give you Power Query (Get & Transform Data) code, and you don't know what to do with it, then CLICK HERE

    Walking the tightrope between genius and eejit...

  3. #3
    Registered User
    Join Date
    10-10-2013
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    49

    Re: Set Excel to look the same on all monitor resolutions

    Hi Olly,

    That works great! I do however have another problem though. The "Home Page" is set to the above, however the worksheet has about 10 tabs which all require their own setting. Is there a way I can apply the above code to each tab (and amend the range)?

  4. #4
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Set Excel to look the same on all monitor resolutions

    Yup. Use this, and amend the sheet / range references as needed:
    Sub zoomfoo(rng As Range)
    rng.Worksheet.Activate
    rng.Select
    ActiveWindow.Zoom = True
    rng.Cells(1, 1).Select
    End Sub
    
    Sub wszoomfoo()
    Dim c As Range, ws As Worksheet
    Set c = Selection
    Set ws = ActiveSheet
    
    Application.ScreenUpdating = False
    
    'Amend this section, to specify all your sheets / ranges
    Call zoomfoo(Worksheets("Sheet1").Range("A1:Y32"))
    Call zoomfoo(Worksheets("Sheet2").Range("A1:E10"))
    Call zoomfoo(Worksheets("Sheet3").Range("A1:AZ60"))
    
    ws.Activate
    c.Select
    Application.ScreenUpdating = True
    End Sub

  5. #5
    Registered User
    Join Date
    10-10-2013
    Location
    London
    MS-Off Ver
    Excel 2003
    Posts
    49

    Re: Set Excel to look the same on all monitor resolutions

    Brilliant!!

    How do I get it to run automatically? I already have code in the file, I have just entered this at the bottom.

    I would like this to run when it opens on each different PC.

  6. #6
    Forum Expert Olly's Avatar
    Join Date
    09-10-2013
    Location
    Darlington, UK
    MS-Off Ver
    Excel 2016, 2019, 365
    Posts
    6,284

    Re: Set Excel to look the same on all monitor resolutions

    In ThisWorkbook module, use:
    Private Sub Workbook_Open()
    Call wszoomfoo
    End Sub

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. ping monitor and RDP from excel
    By tasneem04 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 04-25-2014, 08:59 AM
  2. Excel Help, Monitor a spreadsheet??
    By Kevin Maguire in forum Excel General
    Replies: 1
    Last Post: 09-19-2011, 09:42 AM
  3. New Years Resolutions Suggestions
    By ChemistB in forum The Water Cooler
    Replies: 5
    Last Post: 12-28-2010, 12:30 AM
  4. Monitors and Screen Resolutions
    By squiggler47 in forum The Water Cooler
    Replies: 10
    Last Post: 10-28-2010, 12:06 PM
  5. Change zoom to fit different resolutions
    By jweasl in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-18-2005, 02:05 PM

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