Link to home
Start Free TrialLog in
Avatar of ogir
ogir

asked on

Show MS-WORD menu and toolbar.

I am runing an application that create a ms-word document, but when the word is opened the window does not shows the menu and the toolbar. My code is following:

Dim xapp As Word.Application
Dim xdoc As Word.Document
Dim xsel As Word.Selection
 
Set xapp = New Word.Application
Set xdoc = xapp.Documents.Add
Set xsel = xapp.Selection

'... open file

xapp.WindowState = wdWindowStateMaximize
xapp.PrintPreview = True

Set xsel = Nothing
Set xdoc = Nothing
Set xapp = Nothing


Thanks!
ASKER CERTIFIED SOLUTION
Avatar of adityau
adityau

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ogir
ogir

ASKER

My window application is  appearing on the screen. The program has "xapp.visible = true" but is the toolBar and Menu "File Edit ...." that is not appear in the window.
I tried it. With xapp.Visible=True, Menu and tool bar appears. Without that, it shows word without menu bar.
Avatar of ogir

ASKER

It´s runnig correctly now.
Thanks!
Avatar of ogir

ASKER

It´s runnig correctly now.
Thanks!