Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 42
Default Disable user interaction in VBA

Hi All,

How can you disable user interaction with a workbook while awaiting
completion of running of a few macros? These macros depend on specific
selection of worksheets and if users change the worksheet tabs, they will
break the macros. How can I disable their user interaction with workbook
while macros are running?

I tried the followings which failed:
- changing the cursor shape to xlwait
- Application.ScreenUpdating = False
Application.EnableEvents = False

thanks for your help.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,441
Default Disable user interaction in VBA

Write your macro code to be independent of selection:

Instead of

Worksheets("Sheet1").Select
Range("A12").Select
MyVal = Selection.Value

use

MyVal = Worksheets("Sheet1").Range("A12").Value

Post your code if you need help doing so.

HTH,
Bernie
MS Excel MVP


"LABKHAND" wrote in message
...
Hi All,

How can you disable user interaction with a workbook while awaiting
completion of running of a few macros? These macros depend on specific
selection of worksheets and if users change the worksheet tabs, they will
break the macros. How can I disable their user interaction with workbook
while macros are running?

I tried the followings which failed:
- changing the cursor shape to xlwait
- Application.ScreenUpdating = False
Application.EnableEvents = False

thanks for your 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
Locking User Interaction LABKHAND Excel Programming 0 January 21st 10 03:02 PM
How Email does not need user interaction ? Koulla Excel Discussion (Misc queries) 4 October 15th 08 02:41 PM
Worksheet copy without user interaction Sunicro Excel Programming 0 December 20th 07 07:46 PM
Upload file without user interaction - VBA [email protected] Excel Programming 6 June 23rd 07 01:26 PM
Modeless form for user interaction Arne[_2_] Excel Programming 6 July 15th 03 02:22 PM


All times are GMT +1. The time now is 06:03 PM.

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"