Which profile has been selected?

M

Michael Bauer

Am Fri, 25 Nov 2005 12:51:45 -0800 schrieb news.microsoft.com:

You can use CDO and read the Session.Name property. CDO is an optional
installation from your Office CD.

Sample:
Dim oSess As MAPI.Session
Set oSess = CreateObject("MAPI.Session")
oSess.LogOn , , False, False, , True
Debug.Print oSess.Name
 
J

John Smith

Thanks for your help.
And now I have another question, how can I make sure the LogOn method
executes successfully?
Thanks again.
 
N

news.microsoft.com

I have two profiles and choose one when I start Microsoft Office Outlook XP
or 2003.
How can I get which profile is loaded by VBA? Thanks a lot!
 
M

Michael Bauer

Am Sat, 26 Nov 2005 00:43:17 +0800 schrieb John Smith:

In the context of your first question and by using my sample it will logon
successfully because you´re already loged on via Oultlook and just use that
session (but in CDO).
 
J

John Smith

Wow, thanks again!

Michael Bauer said:
Am Sat, 26 Nov 2005 00:43:17 +0800 schrieb John Smith:

In the context of your first question and by using my sample it will logon
successfully because you´re already loged on via Oultlook and just use that
session (but in CDO).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top