You are prompted to grant permission for ActiveX Controls when you open an Office XP or Office 2003 document (827742)



The information in this article applies to:

  • Microsoft Office Word 2003
  • Microsoft Office Excel 2003
  • Microsoft Office PowerPoint 2003
  • Microsoft Office Outlook 2003
  • Microsoft Office Access 2003
  • Microsoft Office Publisher 2003
  • Microsoft Office FrontPage 2003
  • Microsoft Office XP, All Editions
  • Microsoft Excel 2002
  • Microsoft PowerPoint 2002
  • Microsoft Word 2002
  • Microsoft Visual Basic for Applications 6.4

Important This article contains information about how to modify the registry. Make sure to back up the registry before you modify it. Make sure that you know how to restore the registry if a problem occurs. For more information about how to back up, restore, and modify the registry, click the following article number to view the article in the Microsoft Knowledge Base:

256986 Description of the Microsoft Windows registry

SYMPTOMS

When you open a document in one of the Microsoft Office programs listed in the "Applies to" section, you may be prompted to grant permission for ActiveX Controls to be loaded or to permit the controls to maintain persisted data. Some ActiveX Controls may not load at all.

Additionally, when you import an Office document that contains ActiveX Controls to another program such as a Microsoft SharePoint Team Services Web site, you may receive a warning message that is similar to the following:
This application is about to initialize ActiveX Controls that might be unsafe. If you trust the source of this document, select Yes and the control will be initialized using your document settings.
If you click No, the ActiveX Controls do not load. If you click Yes, the ActiveX Controls load.

CAUSE

This problem occurs when you try to open a document that contains ActiveX Controls that are marked as unsafe for initialization (UFI). By default, the Office programs do not load or activate ActiveX Controls that are not marked as safe for initialization (SFI). This problem also applies to the ActiveX Controls that are included with the Office programs.

WORKAROUND

Note We highly recommend that you do not run ActiveX Controls in documents that are submitted to you by people who you do not know because there is no guarantee that the data that is associated with the control is actually safe to use. However, if you trust the source of the document and the individual or the company that sent it to you, you can load the control and permit it to use persisted data.

Warning Serious problems might occur if you modify the registry incorrectly by using Registry Editor or by using another method. These problems might require that you reinstall your operating system. Microsoft cannot guarantee that these problems can be solved. Modify the registry at your own risk.
To work around this problem and change the way that the Office programs treat ActiveX components, add the UFIControls key to the registry that changes the Office programs behavior. For more information about how to do this, see the "Change the registry settings to UFIControls = 1" section.

Information about the UFI control settings for ActiveX components

When the control is SFI, the Office programs behave the same:
  • If UFIControls is equal to 1 (least secure), 3 or 5: Load (no prompt) the ActiveX control in un-safe mode with the document persisted property values if they exist otherwise with default properties (InitNew).
  • If UFIControls is equal to 2, 4 (most secure) or 6 (default setting): Load (no prompt) the ActiveX control in safe mode with the document persisted property values if they exist otherwise with default properties (InitNew).
UFIControls = 4 is the most secure setting because it does force the Office programs to load UFI controls with default properties but to avoid user confusion with a new behavior for UFI, the default for UFIControls = 6 because the UFI controls load with document persisted property.

Note Every subkey that is listed under the HKEY_CURRENT_USER\SOFTWARE\Microsoft\Office\Common\Security registry key has an equivalent subkey under the following registry keys:
  • HKEY_CURRENT_USER\SOFTWARE\Policies\Microsoft\Office\Common\Security
  • HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office\Common\Security
In Office XP, UFI controls will bring a dialog box before loading, but in the Office programs they were initialized silently. To see the file as they did with Office XP, users must use one of the following methods:
  • Click Yes to continue in the warning message.
  • Change the registry setting to UFIControls = 1.
  • Contact the author of the ActiveX control to make their ActiveX control SFI.
Administrators can set the default by using the Custom Installation Wizard (CIW). For more information about the CIW, see the Office Resource Kit. To do this, visit one of the following Microsoft Web sites:

Office 2003Office XP

Change the registry settings to UFIControls = 1

To modify the registry and add the UFIControl subkey, follow these steps:
  1. Click Start, click Run, type regedit, and then click OK.
  2. Expand the following registry subkey:

    HKEY_CURRENT_USER\SOFTWARE\Microsoft\Office\Common

  3. Right-click Common, point to New, and then click Key.
  4. Type Security, and then press ENTER to name the new subkey.
  5. Right-click Security, point to New, and then click DWORD Value.
  6. Type UFIControls, and then press ENTER to name the value.
  7. Double-click UFIControls.
  8. In the Value data box, type 1, and then click OK.

    Note The available settings for UFIControls are 1 through 6. The most secure setting is 4. The default setting is 6, and the least secure setting is 1. For more information about the valid values for this DWORD Value, see the "Information about the UFI control settings for Active X components" section.
  9. Quit Registry Editor.

Forms3 and ActiveX initialization (Office 2003 and Office XP)

By using the common security registry key, you can instruct the Office 2003 and Office XP programs to set Forms3 ActiveX initialization security for all Office 2003 and Office XP programs that support Forms3. If the setting of the key is 2 or 3, the user is prompted to determine how Forms3 forms will load. The prompt only appears one time per session in a program. The location of the registry key is the following:

HKEY_CURRENT_USER\Software\Microsoft\VBA\Security

In either the registry or policy node, the value name LoadControlsInForms can be set to the following values and respective actions.
Value name:LoadControlsInForms
Value type:REG_DWORD
Value Data:[ 1 | 2 | 3 | 4 ]

Description of the value data

The value data can be explained as follows:
  • Use 1 for a UFI or SFI signed control that supports safe and unsafe mode, load the control in unsafe mode. For an SFI signed control that only supports a safe mode configuration, load the control in safe mode.
  • Use 2 (default setting) for a UFI signed control, if the user responds with a Yes to the prompt, load the control in unsafe mode. If the user responds with a No, load using the default properties. For an SFI control that supports both a safe and unsafe mode, if the user responds to the prompt with a Yes, load the control in unsafe mode. If the user responds with a No, load the control using safe mode. If the SFI control can only support safe mode, load the control in safe mode.
  • Use 3 for a UFI signed control, if the user responds with a Yes to the prompt, load the control in unsafe mode. If the user responds with a No, load the control with its default properties. For an SFI control, load in safe mode.
  • Use 4 for a UFI signed control, load with the default properties of the control. For an SFI control, load in safe mode (considered to be the safest mode).

MORE INFORMATION

For more information about problems with ActiveX Controls, click the following article number to view the article in the Microsoft Knowledge Base:

817112 ActiveX controls do not load or function as expected when you open a document with Office 2003 program


ActiveX Controls are programs and can store data in either the registry or the control itself. ActiveX Controls are similar to Microsoft Visual Basic for Applications (VBA) macros except that they are compiled to a special file type and can be hosted by programs that can support them--for example, Microsoft Word 2002 and Microsoft Excel 2002.

To use an ActiveX control, a control link reference is embedded in the Office document. Office programs can only preserve or migrate ActiveX control link references to new versions of the document if the ActiveX control is activated when the document is opened. A subsequent save of the document if the ActiveX control is disabled saves a version of the document without the link reference (the ActiveX control is removed). Sometimes this is not what you want because you must have the control to view some or all the content of the document.

Not all file formats support ActiveX control linking. Therefore, even if the document is opened with the ActiveX control activated, it will not save it to formats that do not support ActiveX controls.

Note If you let the program run the control and use persisted data, you do so at your own risk.

REFERENCES

For more information about how to work more safely with ActiveX Controls, visit the following Microsoft Web site:For more information about ActiveX controls, see the Office Resource Kit. To do this, visit one of the following Microsoft Web sites:

Office 2003Office XP

Modification Type:MajorLast Reviewed:3/23/2006
Keywords:kbtshoot kbAutomation kbProgramming kberrmsg kbprb KB827742 kbAudEndUser kbAudDeveloper