if you want to display a message while macro is running in a workbook to the user. Check the snapshot below -
and you want to display the message like below
Here is the code:-
Sub displaymss()
Application.ScreenUpdating = False
Application.DisplayStatusBar = True
Application.StatusBar = "Please wait while performing task"
'-------------add your code here-----------------------
Application.StatusBar = False
Application.ScreenUpdating = True
End Sub
try the below link if you want to show a progress bar while macro is running.
ReplyDeletehttp://spreadsheetpage.com/index.php/tip/displaying_a_progress_indicator/
or try the link below
ReplyDeletehttp://www.ozgrid.com/FreeDownloads/DisplayWaitMessage.zip
also visit
ReplyDeletehttp://www.excelvbamacros.com/2012/08/show-progress-bar-in-excel-while-macro.html