Long running operations

  • Thread starter Thread starter Erik Wikström
  • Start date Start date
E

Erik Wikström

Hello

I have an Excel-file that interacts with MATLAB, some of the interactions
can take quite a long time, when that happens a window comes up saying that
"Microsoft Office Excel is waiting for another application to complete an OLE
action. I understand that I should be able to get rid of this window by
setting Application.DisplayAlerts to false during the operation.

However instead I would like to show a model window of my own (without any
buttons or such) with a message like "please wait" and then when the
operation is completed I remove the window. Is that possible?

AFAIK if I use a normal form and run Show() then I will not be able to close
it from the code that created it, that have to be done in code belonging to
the form, is that correct?
 
Hi Erick,

Follow this structure

Sub StartMacro
userform.show
End sub

Sub userform_Activate
Call main
Unload me
end sub

Sub Main
'do something
End sub

Regards

JY
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top