Results 1 to 6 of 6

Application.ScreenUpdating = False. A problem...

Threaded View

  1. #1
    Forum Contributor
    Join Date
    11-26-2008
    Location
    UK
    MS-Off Ver
    Using Excel 2019
    Posts
    317

    Application.ScreenUpdating = False. A problem...

    Hi,

    We recently updated to Windows 7 at work and as a result one of my macros began to run really slowly, presumably because of the large grid size? Anyhow, this was the macro in question...

    Sub CreateRegister()
        
        Sheet1.Range("A" & ActiveCell.Row & ":K" & ActiveCell.Row).Copy Destination:=Sheet1.Range("RegHeadings").Cells(2, 1)
        Range("Names").AdvancedFilter Action:=xlFilterCopy, copytorange:=Range("NamesOut"), criteriarange:=Range("Crit_Prog")
        Sheet2.Activate
        If MsgBox("Select Yes to Print, No to Cancel", vbYesNo, "Print Confirmation") = vbYes Then Range("Register").PrintOut
        Sheets("List of Lessons").Select
        
    End Sub

    I solved the issue by adding:

    Application.ScreenUpdating = False
    at the start of the macro.

    However what this does is to stop the Sheet2.Activate from working. This is important as the user needs to check the register to make sure the details are correct before printing. Can anyone think of a way round this?
    Last edited by Barking_Mad; 11-14-2011 at 08:22 AM.

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