Dynamic CDO profiles: What am I doing wrong?

Dynamic CDO profiles: What am I doing wrong?

Post by j.. » Sat, 29 Jan 2000 04:00:00



I'm trying to get a dynamic CDO profile to work.  When I run the following
code, the LOGON method times out.  The OUTBOX property then automatically
opens a profile window, which has the Server name correct, but the mailbox
name contains an "=" in front of it.

Does the PROFILEINFO parameter only work from web clients interacting with
IIS?  Or can I run this straight from a visual basic application running
on the desktop?  Any help would be appreciated.

The environment is:

   Exchange 5.0
   Outlook 98 Client
   CDO 1.2

The code is:

       Dim objSession As MAPI.Session
        Dim objOutbox As Folder
        Dim objNewMessage As Message
        Dim objRecipients As Recipients
        Dim objOneRecip As Recipient
        Set objSession = New MAPI.Session
        objSession.Logon profileinfo:= "JOE_SERVER" & vbCrLf & "joew"

        Set objOutbox = objSession.Outbox
        Set objNewMessage = objOutbox.Messages.Add
        Set objRecipients = objNewMessage.Recipients
        Set objOneRecip = objRecipients.Add
        With objOneRecip
          .Name = "Joe Wichowski"
          .Type = ActMsgTo
          .Resolve
          ' Get MAPI to determine complete E-mail address.
         End With
         With objNewMessage
         .Subject = "Test VB"
          .Text = "Test VB"
          .Send
         End With

 
 
 

Dynamic CDO profiles: What am I doing wrong?

Post by Rick Spiewa » Sat, 29 Jan 2000 04:00:00


objSession.Logon profileinfo:= "JOE_SERVER" & vbLf & "joew"


Quote:> I'm trying to get a dynamic CDO profile to work.  When I run the following
> code, the LOGON method times out.  The OUTBOX property then automatically
> opens a profile window, which has the Server name correct, but the mailbox
> name contains an "=" in front of it.

> Does the PROFILEINFO parameter only work from web clients interacting with
> IIS?  Or can I run this straight from a visual basic application running
> on the desktop?  Any help would be appreciated.

> The environment is:

>    Exchange 5.0
>    Outlook 98 Client
>    CDO 1.2

> The code is:

>        Dim objSession As MAPI.Session
>         Dim objOutbox As Folder
>         Dim objNewMessage As Message
>         Dim objRecipients As Recipients
>         Dim objOneRecip As Recipient
>         Set objSession = New MAPI.Session
>         objSession.Logon profileinfo:= "JOE_SERVER" & vbCrLf & "joew"

>         Set objOutbox = objSession.Outbox
>         Set objNewMessage = objOutbox.Messages.Add
>         Set objRecipients = objNewMessage.Recipients
>         Set objOneRecip = objRecipients.Add
>         With objOneRecip
>           .Name = "Joe Wichowski"
>           .Type = ActMsgTo
>           .Resolve
>           ' Get MAPI to determine complete E-mail address.
>          End With
>          With objNewMessage
>          .Subject = "Test VB"
>           .Text = "Test VB"
>           .Send
>          End With


 
 
 

1. What am I doing wrong?

Hi,

I'm trying to do a migration upgrade to SBS 2000 from SBS 4.5.  I'm using
the SBS2000 migration upgrade white paper.  I'm at the point of using
exmerge on the SBS4.5. I'm using exmerge3.7 and I get an error stating that
exchange administrator is not installed but, it is.  I use it.  I stoppeed
the IMS just like the paper says.

Any Ideas?

Thanks,
Dan

2. Quicken 2002 and Money 2002

3. HELP: Migrate from Eudora Worldmail???

4. Error 4116 - What am I doing wrong?

5. Outlook Web Access hanging on logon

6. What Am I Doing wrong: GAL replication

7. Public Folder Slowness in Folders with Thousands of Msgs due to "per user read/unread procesing".

8. What am I doing wrong?

9. What am I doing wrong????????

10. CDO 1.21s (Outlook 2002/XP) doesnot allow impersonation and dynamic profile

11. CDO/MAPI dynamic profile

12. How to create dynamic profile in CDO.dll