ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Can you build in a delay... (https://www.excelbanter.com/excel-programming/282716-can-you-build-delay.html)

Jeff Harbin[_2_]

Can you build in a delay...
 
I've got a spreadsheet that opens up, refreshes the data, calculates some
statistics, updates some graphs, and the prints out a report. It all
happens so fast my operators are unsure if it actually does anything (other
than waiting for the printout). Is there a way to build in delays that
wouldn't require operator interaction to show them the status of the
process.

I was thinking of a single cell that had different text in it depending on
the step (ie., updating data, formatting report, printing report, etc.) but
I want to build in a delay function so that the messages don't fly buy so
fast the operator cannot see them.

Thanks,




JON JON

Can you build in a delay...
 

Hello Jeff,

Copy the following lines of codes in between the appropriate place in your
macro. Replace the message as necessary.

Application.StatusBar = "Wait for 5 seconds" ' Show a message to status
bar
Application.Wait Now() + TimeSerial(0, 0, 5) 'Will pause the macro for 5
seconds

Don't forget to put this line at the end of your code.

Application.StatusBar = False 'return to the default status bar

Hope this help.

Jon-jon


"Jeff Harbin" wrote in message
nk.net...
I've got a spreadsheet that opens up, refreshes the data, calculates some
statistics, updates some graphs, and the prints out a report. It all
happens so fast my operators are unsure if it actually does anything

(other
than waiting for the printout). Is there a way to build in delays that
wouldn't require operator interaction to show them the status of the
process.

I was thinking of a single cell that had different text in it depending on
the step (ie., updating data, formatting report, printing report, etc.)

but
I want to build in a delay function so that the messages don't fly buy so
fast the operator cannot see them.

Thanks,






DavidP[_3_]

Can you build in a delay...
 
An obvious solution would be to display a message box by adding something like the following as the last line of the macro

MsgBox "The sheet has been updated by the macro", vbOKOnly, "Processing Completed"

Adapt it to suit your own messages

DavidP

On Mon, 17 Nov 2003 04:26:52 GMT, "Jeff Harbin" wrote:

I've got a spreadsheet that opens up, refreshes the data, calculates some
statistics, updates some graphs, and the prints out a report. It all
happens so fast my operators are unsure if it actually does anything (other
than waiting for the printout). Is there a way to build in delays that
wouldn't require operator interaction to show them the status of the
process.

I was thinking of a single cell that had different text in it depending on
the step (ie., updating data, formatting report, printing report, etc.) but
I want to build in a delay function so that the messages don't fly buy so
fast the operator cannot see them.

Thanks,





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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com