Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Can VBA tell a user a macro is running until it ends?

I am currently writing VBA code to refresh and update an Excel Workbook with
many queries and pivot tables - thus, it takes a few minutes.

Does anyone know if a Message Box can be displayed telling the user that the
Macro is running, and then automatically diasappear after it closes???

Also, I've heard of "Splash Screens" but cannot find any information in the
VBA Help, Microsoft Office Online, or in my VBA books. Does anyone know
anything about these?

This Macro will be used by many people at my office, so some do not always
have the Status Bar displayed which is why I would like to use the MsgBox.

Thanks for your help!
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default Can VBA tell a user a macro is running until it ends?


"weisenb_stev" wrote in message
...
I am currently writing VBA code to refresh and update an Excel Workbook

with
many queries and pivot tables - thus, it takes a few minutes.

Does anyone know if a Message Box can be displayed telling the user that

the
Macro is running, and then automatically diasappear after it closes???



You could use a progress bar. See
http://www.enhanceddatasystems.com/E...rogressBar.htm


Also, I've heard of "Splash Screens" but cannot find any information in

the
VBA Help, Microsoft Office Online, or in my VBA books. Does anyone know
anything about these?



See http://xldynamic.com/source/xld.xlFAQ0007.html


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 69
Default Can VBA tell a user a macro is running until it ends?

weisenb_stev wrote:
I am currently writing VBA code to refresh and update an Excel Workbook with
many queries and pivot tables - thus, it takes a few minutes.

Does anyone know if a Message Box can be displayed telling the user that the
Macro is running, and then automatically diasappear after it closes???

Also, I've heard of "Splash Screens" but cannot find any information in the
VBA Help, Microsoft Office Online, or in my VBA books. Does anyone know
anything about these?

This Macro will be used by many people at my office, so some do not always
have the Status Bar displayed which is why I would like to use the MsgBox.

Thanks for your help!



create userform and set ShowModal to false


below is a code to show how to use it.
lblMessage is a lable on it.



Load frmWait
frmWait.lblMessage = "Please wait..."
frmWait.Show
DoEvents

.... your job here ....



unload frmWait

  #4   Report Post  
Posted to microsoft.public.excel.programming
KR KR is offline
external usenet poster
 
Posts: 121
Default Can VBA tell a user a macro is running until it ends?

In addition to the other excellent suggestions, I sometimes use the
statusbar to show enough information for the user to know the program is
still running, for example, if I am looping through 10,000 records, I might
use something like

For i = 1 to 10,000
Application.Statusbar= "Calculating record " & cstr(i) & " of 10,000"
'code to actually process each record
Next i

Then just before end sub, you need to clear the statusbar using:
Application.statusbar = false

HTH, Keith

"weisenb_stev" wrote in message
...
I am currently writing VBA code to refresh and update an Excel Workbook

with
many queries and pivot tables - thus, it takes a few minutes.

Does anyone know if a Message Box can be displayed telling the user that

the
Macro is running, and then automatically diasappear after it closes???

Also, I've heard of "Splash Screens" but cannot find any information in

the
VBA Help, Microsoft Office Online, or in my VBA books. Does anyone know
anything about these?

This Macro will be used by many people at my office, so some do not always
have the Status Bar displayed which is why I would like to use the MsgBox.

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
2008 East Coast US Excel User Conference - Regular registration ends Damon Longworth Excel Discussion (Misc queries) 0 August 29th 08 01:17 PM
2008 East Coast US Excel User Conference - Regular registration ends Damon Longworth Excel Worksheet Functions 0 August 29th 08 01:17 PM
disable user running macro from Tools Macro Steve Simons Excel Discussion (Misc queries) 4 September 28th 06 06:28 AM
PasteSpecial xlPasteFormats ends macro itarnak Excel Programming 4 October 12th 05 02:44 PM
Message Window to tell user "Macro Running" keyt Excel Programming 2 October 4th 03 05:28 PM


All times are GMT +1. The time now is 10:31 AM.

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

About Us

"It's about Microsoft Excel"