PRB: Permission Denied - Scripting ActiveX Documents

ID: Q239636


The information in this article applies to:
  • Microsoft Internet Explorer (Programming) versions 4.0, 4.01, 4.01 SP1, 4.01 SP2, 5


SYMPTOMS

When scripting to an ActiveX Document like Word, Excel, or a Visual Basic document, the following error message appears:

Permission Denied.


CAUSE

For security reasons, Internet Explorer does not allow scripting of ActiveX Documents.


STATUS

This behavior is by design.


MORE INFORMATION

ActiveX Controls (OCX) can be placed on a HTML page and be scripted. However, the same is not applicable for ActiveX Documents (VBD) or other ActiveX documents like Microsoft Word Documents or Excel Spreadsheets.

An ActiveX Document created by Microsoft Office like Microsoft Word, Excel, and cannot be scripted from an HTML frame.

Active Documents in Microsoft Word and other Active documents have object models that might be unsafe, such as accessing a hard drive or saving files. Also, there is no way to sign an Active document, so Internet Explorer prevents access to an Active Document from within a frame page script for security reasons.

Assuming the following code is belongs to a frameset page. The source of frames(1) is a Microsoft Word Document:


<HTML>
  <HEAD>
    <TITLE>frame1</TITLE>
    <SCRIPT LANGUAGE="VBSCRIPT">
      Msgbox top.frames(0).document.title
      Msgbox top.frames(1).document.title
    </SCRIPT>
  </HEAD>
  <BODY>
  </BODY>
</HTML> 
The first message box appears showing the title "frame1". And then an error message appears stating "member not found".


REFERENCES

For more information, please see the MSDN Web Workshop:

http://msdn.microsoft.com/workshop/default.asp

Additional query words: Script VBD

Keywords : kbActiveDocs kbGrpInet kbDSupport
Version : WINDOWS:4.0,4.01,4.01 SP1,4.01 SP2,5
Platform : WINDOWS
Issue type : kbprb


Last Reviewed: January 21, 2000
© 2000 Microsoft Corporation. All rights reserved. Terms of Use.