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?
Bookmarks