(Solved) – How I make excel show a await message while execute a macro?

  • by

I have a macro that consulte to Database (in this case is a excel workbook), but when the macro consulte to database, it take 30 sec, and the user thinks that the program is broke. I tried with “Application.StatusBar = “Refresh File. “”, but the user canĀ“t see the sentence, the best way is a msgbox with the message “Await a moment”, and, when the macro is finished, this message is closed. Do you help me with the code? I think the solution is this way:

Sub Button1_Click()
'Call msgbox with message "Await a moment"
Dim x As Long
For x = 0 To 2000000000 Step 1
'The msgbox is closed
End Sub

I think the solution is a msgbox but it is a another option, Go Ahead!

Leave a Reply

Your email address will not be published. Required fields are marked *