PRB: Access Denied Using CDO from VBScriptLast reviewed: February 9, 1998Article ID: Q179104 |
The information in this article applies to:
SYMPTOMSYou may receive the error "Access Denied" trying to invoke certain properties of Collaboration Data Objects (CDO) objects from VBScript (VBS) when the same operation succeeds from a Visual Basic application.
STATUSThis behavior is by design to ensure the security of message stores and address books.
MORE INFORMATION
Steps to Reproduce Behavior
'Following is the VBScript code to reproduce the behavior: 'This sample assumes that the CDO library is installed on the test 'computer and that a profile named "Microsoft Outlook" exists. Sub but_OnClick Dim objSession Set objSession = CreateObject("mapi.session") objSession.Logon "Microsoft Outlook" MsgBox objSession.Inbox.Messages.Count 'This fails w/Access Denied objSession.Logoff End SubNOTE: This issue does not occur with all properties and methods; some operations (like sending messages) and some properties operate as expected.
REFERENCESFor information on where to acquire the most recent version of the CDO library tested for client-side use, please see the following article in the Microsoft Knowledge Base:
ARTICLE-ID: Q171440 TITLE : INFO: Where to Acquire the Active Messaging LibrariesFor additional information about Collaboration Data Objects versus Active Messaging, please see the following article in the Microsoft Knowledge Base:
ARTICLE-ID: Q176916 TITLE : INFO: Active Messaging and Collaboration Data Objects (CDO) Keywords : ActMsg OLEMSG cdo Version : WINDOWS:1.1,1.2 Platform : WINDOWS Issue type : kbprb |
================================================================================
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |