View Single Post
  #1  
Old January 4th 08, 10:31 PM posted to microsoft.public.outlook.program_vba
Werner Leupold
external usenet poster
 
Posts: 1
Default Logon to Outlook from VB

Hi NG,
I try to access Outlook from VB6.
That works fine if Outlook is not password protected.
Whenever the outlook application is password protected it is not possible to
use the following code snipplet:

Dim oApp As New Outlook.Application
Dim oNS As Outlook.NameSpace
Set oApp = New Outlook.Application
Set oNS = oApp.GetNamespace("MAPI")

oNS.Logon "Outlook", "myPassword", False, True

Though the password is correct there will be a password dialog displayed and
I have to type in the password.
No matter if Outlook is running or not.

Thanks for helping

Werner
Ads