H
Hans Zybura
Hi,
I want to hand our customers using MacOS 10.1 (or later) and MacOffice (X or
2004) a simple applescript, which is meant to do the following:
- start Word
- open a new document with our special template attached
- do some more VBA code
Basically it looks like:
tell application "Microsoft Word"
launch
do Visual Basic "
Documents.Add Template:=/"ourTemplate.dot/", NewTemplate:=False
"
end tell
In fact there will be a lot more lines of VBA code following the initial
one, but there's a catch even in these few lines: When the user has set Word
to start with the Project Gallery, the applescript will throw an error when
reaching the line containing "do Visual Basic...". I've done a lot of
experimentation and an extensive search on this, but found some advice
concerning a similar problem with Excel only. That did not change the
problem with Word.
Is there a way to make an applescript stop the Project Gallery from showing
up or - next best thing - to close it immediately? Without changing the
users settings to "Do not start Word with automatically showing up the
damned Project Gallery" beforehand?
Thanks in advance
Hans
I want to hand our customers using MacOS 10.1 (or later) and MacOffice (X or
2004) a simple applescript, which is meant to do the following:
- start Word
- open a new document with our special template attached
- do some more VBA code
Basically it looks like:
tell application "Microsoft Word"
launch
do Visual Basic "
Documents.Add Template:=/"ourTemplate.dot/", NewTemplate:=False
"
end tell
In fact there will be a lot more lines of VBA code following the initial
one, but there's a catch even in these few lines: When the user has set Word
to start with the Project Gallery, the applescript will throw an error when
reaching the line containing "do Visual Basic...". I've done a lot of
experimentation and an extensive search on this, but found some advice
concerning a similar problem with Excel only. That did not change the
problem with Word.
Is there a way to make an applescript stop the Project Gallery from showing
up or - next best thing - to close it immediately? Without changing the
users settings to "Do not start Word with automatically showing up the
damned Project Gallery" beforehand?
Thanks in advance
Hans