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

All of a sudden screenupdating =false does not work
Now screen updating does not seem to work- I added the msgboxes to see
what the variable is- it is False the first time and True the second
time- what is triggering the change?




When I run this code the value of screenupdating goes from False to
True when the msgbox is displayed?
I have no idea why - (Excel 2007)

Sub Macro1()


Application.ScreenUpdating = False
Application.DisplayAlerts = False
mybook = ActiveWorkbook.Name


myfolder = Range("i1")
myfile = Range("i2")
myfile = myfolder & myfile
MsgBox Application.ScreenUpdating


'
Application.StatusBar = "opening ap.txt"
Workbooks.OpenText Filename:= _
myfile _
, Origin:=xlWindows, StartRow:=1, DataType:=xlFixedWidth,
FieldInfo:= _
Array(Array(0, 9), Array(6, 1), Array(15, 9), Array(23, 1),
Array(47, 9), Array(67, 1), _
Array(74, 9), Array(82, 9), Array(96, 9), Array(107, 1))


MsgBox Application.ScreenUpdating

'more code
End Sub

  #2   Report Post  
Posted to microsoft.public.excel.programming
Ray Ray is offline
external usenet poster
 
Posts: 267
Default Screenupdating=false not working

Steve -

It's got to be something with the external workbook that you're
opening .... I tried it with the part of the code 'commented out' and
it worked fine (msgbox = false both times).

ray

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

On Aug 8, 2:53 pm, SteveF wrote:
All of a suddenscreenupdating=false does not work
Now screen updating does not seem to work- I added the msgboxes to see
what the variable is- it is False the first time and True the second
time- what is triggering the change?

When I run this code the value ofscreenupdatinggoes from False to
True when the msgbox is displayed?
I have no idea why - (Excel 2007)

Sub Macro1()

Application.ScreenUpdating= False
Application.DisplayAlerts = False
mybook = ActiveWorkbook.Name

myfolder = Range("i1")
myfile = Range("i2")
myfile = myfolder & myfile
MsgBox Application.ScreenUpdating

'
Application.StatusBar = "opening ap.txt"
Workbooks.OpenText Filename:= _
myfile _
, Origin:=xlWindows, StartRow:=1, DataType:=xlFixedWidth,
FieldInfo:= _
Array(Array(0, 9), Array(6, 1), Array(15, 9), Array(23, 1),
Array(47, 9), Array(67, 1), _
Array(74, 9), Array(82, 9), Array(96, 9), Array(107, 1))

MsgBox Application.ScreenUpdating

'more code
End Sub



This is happening even when opening a file is not involved

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
application.screenupdating = false not working Sabre Excel Programming 11 April 13th 07 07:46 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 11:59 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"