Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 49
Default When to use screenupdating?

hi,

I'm having some difficulty in getting the screenupdating to work.
Firstly, I have 1 small module, module1 (reside in sheet1), which call
another moduel, module2, and this also call another 4 mdoules, module3 to
module6 say.

With module3 (work on sheet3), and module5 (work on sheet4), both is
required to insert columns or rows to copy and add data, and it seem that I
must activate or select the sheet under either modules before I can add or
copy. Please let me know if there is another way? 'Cause I notice that the
moment a sheet, is Selected, the screenupdating stop working. I have declared
ScreenUpdating=Flase inside Module1, Module3 & Module5. But They don't work
in module 3 and 5.

Could someone pleaser let me the rule in using ScreenUpdating? Ie, if like
me, who has about 4 to 6 modules interrelated?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 123
Default When to use screenupdating?

Once screenupdating is set to false, it is not automatically turned on
after code is executed. You have to set it to true in your code, or you
have to quit excel and restart it.

When screenupdating is set to false, if you are selecting any ranges on
the sheet which was active just before setting screenupdating to false,
then you can see the on the screen that different ranges are being
selected.

Well to add rows / columns or data it is not neccessary to activate or
select the sheet.

See bellow example, run it with Sheet1 being active, it will add column,
row and data in to sheet2 without selecting or activating it.

With Worksheets("Sheet2")
With .Range("A5")
.EntireColumn.Insert
.Value = "xyz"
End With
With .Range("D5")
.EntireRow.Insert
.Value = "abc"
End With
End With
End Sub

Sharad


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 49
Default When to use screenupdating?

Hi Sharad,

Is it possible to insert or hide a column without selecting a sheet first?
Ie, could I insert a column in sheet3, while sheet 1 is activated?

thanks
Augustus
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
about screenupdating baha Excel Discussion (Misc queries) 0 March 25th 10 06:16 AM
Screenupdating Fu Manchu Excel Programming 2 January 11th 04 02:08 PM
ScreenUpdating Problem pjhageman[_8_] Excel Programming 1 January 10th 04 09:15 PM
.ScreenUpdating Problem? Phil Hageman[_3_] Excel Programming 1 December 12th 03 12:32 AM
ScreenUpdating not effective Boaz Michaely Excel Programming 1 November 11th 03 07:50 PM


All times are GMT +1. The time now is 02:05 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"