Application.ScreenUpdating = False Not Working

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi, I have the following code, but the screen updating line isn't working...
I'm sure I'm doing something wrong (the the code otherwise is working, but is
messy):


------------------------------------
Public Sub ACSButton_Click()
ACSButton.Caption = "Click Here to Load ACS Services"

With Worksheets("Solution Map")
Application.ScreenUpdating = False
Worksheets("Solution Map").Activate
Worksheets("Solution Map").Range("AA42:AD613").Select
Worksheets("Solution Map").Range("AA42:AD613").Copy
Worksheets("Solution Map").Range("AE42").PasteSpecial
xlPasteValues
With .Range("AE42:AH613")
Worksheets("Solution Map").Activate
.Sort Key1:=Worksheets("Solution Map").Range("AE42"),
Order1:=xlDescending, _
Header:=xlNo, OrderCustom:=1, MatchCase:=False,
Orientation:=xlTopToBottom
End With
End With
Worksheets("Solution Map").Activate
Worksheets("Solution Map").Range("AE42:AH613").Copy
Worksheets("ACS").Activate
Worksheets("ACS").Range("A7").PasteSpecial xlPasteValues
Worksheets("ACS").Range("A7").Select
Worksheets("Solution Map").Activate
Worksheets("Solution Map").Range("AE42:AH613").Clear
Worksheets("Solution Map").Range("C1").Select
Worksheets("ACS").Activate
Application.ScreenUpdating = True
End Sub

--------------------------
 
Shelly said:
hmmm, now I'm getting an error

"Object library invalid or contains references to object definitions that
could not be found"

And the first row [Public Sub ACSButton_Click()] is highlighted.


AAACCCKKK!!! Now I'm getting this with EVERY sheet that has code!
I tried closing and reopening Excel, but it didn't help.

OH MY - This is a workbook I've been worrking on for WEEKS and is due to my
manager in the morning.... AACCCKKK!!

Anyone with any ideas?
 
hmmm, now I'm getting an error

"Object library invalid or contains references to object definitions that
could not be found"

And the first row [Public Sub ACSButton_Click()] is highlighted.
----------------------
Public Sub ACSButton_Click()
Application.ScreenUpdating = False
ACSButton.Caption = "Click Here to Load ACS Services"
With Worksheets("Solution Map")
Worksheets("Solution Map").Activate
Worksheets("Solution Map").Range("AA42:AD613").Select
Worksheets("Solution Map").Range("AA42:AD613").Copy
Worksheets("Solution Map").Range("AE42").PasteSpecial xlPasteValues
With .Range("AE42:AH613")
Worksheets("Solution Map").Activate
.Sort Key1:=Worksheets("Solution Map").Range("AE42"),
Order1:=xlDescending, _
Header:=xlNo, OrderCustom:=1, MatchCase:=False,
Orientation:=xlTopToBottom
End With
End With
Worksheets("Solution Map").Activate
Worksheets("Solution Map").Range("AE42:AH613").Copy
Worksheets("ACS").Activate
Worksheets("ACS").Range("A7").PasteSpecial xlPasteValues
Worksheets("ACS").Range("A7").Select
Worksheets("Solution Map").Activate
Worksheets("Solution Map").Range("AE42:AH613").Clear
Worksheets("Solution Map").Range("C1").Select
Worksheets("ACS").Activate
Application.ScreenUpdating = True
End Sub
-------------
 
Back
Top