?
Solved

MS Word: How to open a document with disabled Design Mode?

Posted on 2003-03-12
13
Medium Priority
?
1,111 Views
Last Modified: 2012-05-04
I have a Word document, which contains lot of Radio buttons. Now, when I open the document, design mode is enabled automatically. As I would like to send this document to other users I need it opened with disabled Design Mode. Otherwise radio buttons are selected instead of turning on. Any idea how to do this?

I tried already with "ActiveDocument.ToggleDesignMode" on event Document.open, but this code gets not executed.
0
Comment
Question by:fmokry
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 2
  • 2
  • +3
13 Comments
 
LVL 5

Expert Comment

by:TigerMan
ID: 8119276
Try this one:

If CommandBars("Control Toolbox").Visible = True Then
    ActiveDocument.ToggleFormsDesign
End If

Dave
0
 

Author Comment

by:fmokry
ID: 8119368
Hi Tigerman, I tried this also in event Document.Open, but as mentioned before, the code is not executed.
0
 

Author Comment

by:fmokry
ID: 8119409
Hi Tigerman, I tried this also in event Document.Open, but as mentioned before, the code is not executed.
0
NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

 
LVL 5

Expert Comment

by:TigerMan
ID: 8119421
Maybe it needs to run from a template file.

See Open Event in the online help.

dave
0
 
LVL 1

Expert Comment

by:MacroWizard
ID: 8119652
I think there is more than one thing going on here since this shouldn't be happening. Can you send the document to me for a look-see?

linda.duguay@leewood.com
0
 

Author Comment

by:fmokry
ID: 8120329
I'm sorry, the document is Company Confidential
0
 
LVL 11

Expert Comment

by:Steiner
ID: 8126142
Have you tried
If CommandBars("Control Toolbox").Visible = True Then
   ActiveDocument.ToggleFormsDesign
End If

in the Document_New event, too?
0
 

Author Comment

by:fmokry
ID: 8126918
I added

  If CommandBars("Control Toolbox").Visible = True Then
    ActiveDocument.ToggleFormsDesign
  End If

now for Document_New event also. But again, the code isn't executed. Additional I added a button with a simple MsgBox statement. But no popup appears. So, this code isn't executed also. Is there anything special to make VB code in Word executable?
0
 
LVL 11

Expert Comment

by:Steiner
ID: 8127946
Do you have macros enabled??
Another thing to try whether macros are executed when you open a document:

Put a

Sub AutoOpen
  Msgbox "Open"
End Sub

into a module.

This one should too fire when the document is opened. It that code is executed, try putting the lines with the ToggleFormsDesign here.
0
 
LVL 1

Expert Comment

by:MacroWizard
ID: 8130325
Does this happen with only this one document or can you replicate the situation with another document as well?
0
 

Author Comment

by:fmokry
ID: 8131003
I got it! The problem was the security level that has been set to High (Tools => Macros => Security). I defined this now as medium and now Word is asking if I allow to execute the macros.

However, thank you for your support!!!

0
 
LVL 3

Expert Comment

by:PoshDog
ID: 9561469
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
PAQ/Refund - sorry Steiner, although you'd hinted at the solution
Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

PoshDog
EE Cleanup Volunteer
0
 
LVL 1

Accepted Solution

by:
Computer101 earned 0 total points
ID: 9610776
PAQed, with points refunded (20)

Computer101
E-E Admin
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article helps those who get the 0xc004d307 error when trying to rearm (reset the license) Office 2013 in a Virtual Desktop Infrastructure (VDI) and/or those trying to prep the master image for Microsoft Key Management (KMS) activation. (i.e.- C…
Outlook for dependable use in a very small business   This article is about using the Outlook application (part of Microsoft Office) in a very small business, or for homeowners where dependability and reliability are critical requirements. This …
The viewer will learn how to simulate a series of coin tosses with the rand() function and learn how to make these “tosses” depend on a predetermined probability. Flipping Coins in Excel: Enter =RAND() into cell A2: Recalculate the random variable…
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question