problem with msgbox statement causing an error when called in auto

P

Peter

I have a VBA application which people install by copying to their
microsoft\word\startup folder

I would like to display a message the first time the user runs this template.

The tempate contains a sub autoexec that runs then the template is first run

Sub autoexec()
Dim mastatus As String
....
If mastatus = "First time run" Then
... do welcome to first time users stuff
.... set mastatus to this is not done in future
beep
msgbox "hello ... "


The autoexec runs fine and I hear the beep the first time it is run. Bur the
msgbox causes the following error...

"The command cannot be performed because a dialog box is open. Click Ok, and
then close open dialog boxes to continue"

I guess this measn taht the welcome message is preventing Word from
correctrly opening up.

How can I display a message the first time the .dotm file is used and not
interfere with word's opening process.

Any help will be gratefully received,
PeterEvans
 
P

Peter

Sharing only seems reasonable when others have assisted me.

I'll post a followup message giving a link to the applicaiton I have been
working on and the installation and welcome process. I would be very
interested in people's comments on the process. While I have tested it in a
number of environments I am always interested in making the process as robust
as possible

PeterEvans
 

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

Top