Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Screenupdating = FALSE not working

I have an Excel model with several VBA macros that I have been maintaining in
Excel 2003 for years with no issues. I recently updated to Office 2007, made
some adjustments to the model, and it works fine on my machine (and fine on
some of my coworkers' machines). However, the exact same file when run on
other coworkers' machines is having issues where the
"Application.screenupdating" is being set to true whenever the code switches
worksheets or workbooks. For example:

Sub ProcessName()
Application.Screenupdating = FALSE
Sheets("Sheet 1").Range("Range 1").clearcontents
Sheets("Sheet 2").Range("Range 2").clearcontents
'Up to this point, Screenupdating=FALSE on ALL machines
Sheets("Sheet 3").Select
'At this point, Screenupdating=FALSE on some machines and TRUE on others
Range("Range 3").Select
Selection.Validation.Delete
Application.Screenupdating = TRUE
End Sub

Again, when running on some machines - no problem (screenupdating remains
set to false at all times), but when run on another machines, it switches to
true. We all are running Office 2007. I have seen many posts on various
forums regarding similar issues, but nothing regarding screenupdating working
on one machine but not another.

Is there an Excel Options setting that could be different between our
machines that could be causing this? Thanks for any help.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,565
Default Screenupdating = FALSE not working

Try it this way:

Sub ProcessName()
Application.Screenupdating = FALSE
Sheets("Sheet 1").Range("Range 1").clearcontents
Sheets("Sheet 2").Range("Range 2").clearcontents
'Up to this point, Screenupdating=FALSE on ALL machines
Sheets("Sheet 3").Range("Range 3").Validation.Delete
Application.Screenupdating = TRUE
End Sub



"VBAActuary" wrote in message
...
I have an Excel model with several VBA macros that I have been maintaining
in
Excel 2003 for years with no issues. I recently updated to Office 2007,
made
some adjustments to the model, and it works fine on my machine (and fine
on
some of my coworkers' machines). However, the exact same file when run on
other coworkers' machines is having issues where the
"Application.screenupdating" is being set to true whenever the code
switches
worksheets or workbooks. For example:

Sub ProcessName()
Application.Screenupdating = FALSE
Sheets("Sheet 1").Range("Range 1").clearcontents
Sheets("Sheet 2").Range("Range 2").clearcontents
'Up to this point, Screenupdating=FALSE on ALL machines
Sheets("Sheet 3").Select
'At this point, Screenupdating=FALSE on some machines and TRUE on others
Range("Range 3").Select
Selection.Validation.Delete
Application.Screenupdating = TRUE
End Sub

Again, when running on some machines - no problem (screenupdating remains
set to false at all times), but when run on another machines, it switches
to
true. We all are running Office 2007. I have seen many posts on various
forums regarding similar issues, but nothing regarding screenupdating
working
on one machine but not another.

Is there an Excel Options setting that could be different between our
machines that could be causing this? Thanks for any help.



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Screenupdating = FALSE not working

Thank you for the response. Unfortunately, the code I provided as an example
is an extremely simplified excerpt from the larger model (I should have
clarified). The model contains thousands of lines of code over several
modules and userforms, and requires the opening and closing of other Excel
workbooks. So I need to understand what is causing the issue, as
unfortunately I don't think any easy work-around will suffice here.

"JLGWhiz" wrote:

Try it this way:

Sub ProcessName()
Application.Screenupdating = FALSE
Sheets("Sheet 1").Range("Range 1").clearcontents
Sheets("Sheet 2").Range("Range 2").clearcontents
'Up to this point, Screenupdating=FALSE on ALL machines
Sheets("Sheet 3").Range("Range 3").Validation.Delete
Application.Screenupdating = TRUE
End Sub



"VBAActuary" wrote in message
...
I have an Excel model with several VBA macros that I have been maintaining
in
Excel 2003 for years with no issues. I recently updated to Office 2007,
made
some adjustments to the model, and it works fine on my machine (and fine
on
some of my coworkers' machines). However, the exact same file when run on
other coworkers' machines is having issues where the
"Application.screenupdating" is being set to true whenever the code
switches
worksheets or workbooks. For example:

Sub ProcessName()
Application.Screenupdating = FALSE
Sheets("Sheet 1").Range("Range 1").clearcontents
Sheets("Sheet 2").Range("Range 2").clearcontents
'Up to this point, Screenupdating=FALSE on ALL machines
Sheets("Sheet 3").Select
'At this point, Screenupdating=FALSE on some machines and TRUE on others
Range("Range 3").Select
Selection.Validation.Delete
Application.Screenupdating = TRUE
End Sub

Again, when running on some machines - no problem (screenupdating remains
set to false at all times), but when run on another machines, it switches
to
true. We all are running Office 2007. I have seen many posts on various
forums regarding similar issues, but nothing regarding screenupdating
working
on one machine but not another.

Is there an Excel Options setting that could be different between our
machines that could be causing this? Thanks for any help.



.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,565
Default Screenupdating = FALSE not working

The best I can do is recommend that you purge your code of the Select method
and use the direct address method as illustrated in the snippet I suggested.
That eliminates the need for the ScreenUpdating in 90 percent of the cases.
Every use of Select tries to trigger a screen update. Some versions of
Excel might react differently to the ScreenUpdating code feature.


"VBAActuary" wrote in message
...
Thank you for the response. Unfortunately, the code I provided as an
example
is an extremely simplified excerpt from the larger model (I should have
clarified). The model contains thousands of lines of code over several
modules and userforms, and requires the opening and closing of other Excel
workbooks. So I need to understand what is causing the issue, as
unfortunately I don't think any easy work-around will suffice here.

"JLGWhiz" wrote:

Try it this way:

Sub ProcessName()
Application.Screenupdating = FALSE
Sheets("Sheet 1").Range("Range 1").clearcontents
Sheets("Sheet 2").Range("Range 2").clearcontents
'Up to this point, Screenupdating=FALSE on ALL machines
Sheets("Sheet 3").Range("Range 3").Validation.Delete
Application.Screenupdating = TRUE
End Sub



"VBAActuary" wrote in message
...
I have an Excel model with several VBA macros that I have been
maintaining
in
Excel 2003 for years with no issues. I recently updated to Office 2007,
made
some adjustments to the model, and it works fine on my machine (and
fine
on
some of my coworkers' machines). However, the exact same file when run
on
other coworkers' machines is having issues where the
"Application.screenupdating" is being set to true whenever the code
switches
worksheets or workbooks. For example:

Sub ProcessName()
Application.Screenupdating = FALSE
Sheets("Sheet 1").Range("Range 1").clearcontents
Sheets("Sheet 2").Range("Range 2").clearcontents
'Up to this point, Screenupdating=FALSE on ALL machines
Sheets("Sheet 3").Select
'At this point, Screenupdating=FALSE on some machines and TRUE on
others
Range("Range 3").Select
Selection.Validation.Delete
Application.Screenupdating = TRUE
End Sub

Again, when running on some machines - no problem (screenupdating
remains
set to false at all times), but when run on another machines, it
switches
to
true. We all are running Office 2007. I have seen many posts on various
forums regarding similar issues, but nothing regarding screenupdating
working
on one machine but not another.

Is there an Excel Options setting that could be different between our
machines that could be causing this? Thanks for any help.



.



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
screenupdating=false not working [email protected] Excel Programming 1 July 18th 08 09:58 PM
Screenupdating=false not working SteveF[_3_] Excel Programming 2 August 9th 07 06:16 PM
'Application.ScreenUpdating = False' isn't working Dan R. Excel Programming 6 March 2nd 07 01:10 AM
ScreenUpdating = False not working Jim Thomlinson Excel Programming 2 December 14th 06 02:45 AM
ScreenUpdating = False not working Corey Excel Programming 0 December 14th 06 12:33 AM


All times are GMT +1. The time now is 09:20 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"