Missing tool bar when creating new document

M

melon

I am using the following to create a new Word document, where
TemplatePath is the .dot file. It works but the menu bar and tool bar
is missing.

ApplicationClass app = new ApplicationClass();

Document doc = app.Documents.Add(ref TemplatePath, ref
Missing, ref Missing, ref True);
doc.Activate();

If I use app.Documents.Open, then the menu bar and tool bars show up
as expected. Any clue?
 
C

Cindy M.

Hi Melon,

Which version of Word?

If you right-click this template file in Windows Explorer:
- is the "New" command the default?
- if you choose the "New" command it should generate a new document,
based on the template. Do you see the toolbars and menu?
I am using the following to create a new Word document, where
TemplatePath is the .dot file. It works but the menu bar and tool bar
is missing.

ApplicationClass app = new ApplicationClass();

Document doc = app.Documents.Add(ref TemplatePath, ref
Missing, ref Missing, ref True);
doc.Activate();

If I use app.Documents.Open, then the menu bar and tool bars show up
as expected. Any clue?

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question
or reply in the newsgroup and not by e-mail :)
 

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