I have some code in a VB6 app that opens a Word doc based on a template. It
looks like this:

Dim wordApp As Word.Application
Set wordApp = CreateObject("Word.Application")
wordApp.Documents.Add Template:=(strPathToTemplate), NewTemplate:=False
wordApp.Application.Visible=True

When I create a doc manually, everything works as expected. However, when I
open it from this code, the Word window opens with no toolbars visible.

Any ideas would be helpful.

RE: Creating word doc with FILLIN field hides all toolbars by oldman

oldman
Sun Jul 01 22:16:00 CDT 2007

Hi,

I created a template with no visible toolbars. When I opened a document from
VBA using the template it kept the existing toolbars open. You may try
looking at at the code in the template (there is code that is automatically
executing depending on the name of the modules) that may be closing toolbars.

You may also add code such as this to your VB program to guarantee that the
toolbars are opened:
CommandBars("Formatting").Visible = False
CommandBars("Standard").Visible = False

old man

"Barry Gilbert" wrote:

> I have some code in a VB6 app that opens a Word doc based on a template. It
> looks like this:
>
> Dim wordApp As Word.Application
> Set wordApp = CreateObject("Word.Application")
> wordApp.Documents.Add Template:=(strPathToTemplate), NewTemplate:=False
> wordApp.Application.Visible=True
>
> When I create a doc manually, everything works as expected. However, when I
> open it from this code, the Word window opens with no toolbars visible.
>
> Any ideas would be helpful.