473,395 Members | 1,504 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

How to : read outlook profile and find path of PSTs

FE
> Guys,

I need to create a program (VB) to dump the outlook profile of a user.

By dump I mean a report such as :

User : Mr A
* Folder 1 : exchange mailbox
* Folder 2 : c:\data\pst1.pst
* Folder 2 : c:\data\pst2.pst

I have no problem to do this with the outlook component, except that I don't find any property find the path of the PST (c:\data\pst1.pst)

I have no idea if the outlook component can do that. Any idea ? If there is already a tool to do that, please inform me
Thanks
--

FE
Nov 19 '05 #1
1 5703
"FE" <fr******@esnouf.net> wrote in message
news:ec**************@tk2msftngp13.phx.gbl
Guys,

I need to create a program (VB) to dump the outlook profile of a
user.

By dump I mean a report such as :

User : Mr A
* Folder 1 : exchange mailbox
* Folder 2 : c:\data\pst1.pst
* Folder 2 : c:\data\pst2.pst

I have no problem to do this with the outlook component, except that
I don't find any property find the path of the PST (c:\data\pst1.pst)


AFAIK, it isn't directly exposed via any object available to VB; you can
always scan the registry and read the info there.

It is possible to get it via the StoreID property of the folders but the
value is buried inside a hex string and you'd have to pull that apart
yourself:

Private Sub Main()
Dim o As Outlook.Application
Dim n As NameSpace
Dim f As MAPIFolder
Dim s As String
Dim x As Long
Set o = CreateObject("outlook.application")
Set n = o.GetNamespace("MAPI")
n.Logon
For Each f In n.Folders
Debug.Print f.Name
s = f.StoreID
Debug.Print s
For x = 1 To Len(s) - 1 Step 2
Debug.Print Chr$("&H" & Mid$(s, x, 2));
Next
Debug.Print
Next
n.Logoff
Set n = Nothing
Set o = Nothing
End Sub

Nov 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Fritz Switzer | last post by:
Can anyone provide a small snippet in C# that pulls out the Contacts in Outlook XP. I've seen a couple of examples in C++ and VB in previous newsgroup posts, but either the originals didn't work...
3
by: Robert Tarantino | last post by:
Hello, I am trying to find a way to create a scheduled task or service that will copy my local profile folders under "Documents and settings" to a network drive. This would allow me to restore...
0
by: Bob | last post by:
I have been using "mapi" to send mail from my vb applications for some time. I am now working in vb.net. The problem I am having now is that I need the "from" address to be different than the...
4
by: PitchBlackSheep | last post by:
I have an office of Real Estate agents who use our (single) Access 2000 database to keep track of clients. Our agents email our clients everyday using Outlook 2000. I'm trying to find a way to...
3
by: FE | last post by:
Guys, I need to create a program (VB) to dump the outlook profile of a user. By dump I mean a report such as : User : Mr A * Folder 1 : exchange mailbox * Folder 2 : c:\data\pst1.pst *...
1
by: srinivas | last post by:
Hi, i'm trying to retreive the appointments from different profiles of outlook. My outlook has 3 profiles created.('Sample1','Sample2','Sample3') my form contains 3 buttons.each one for each...
9
by: Srinivas | last post by:
hi all how to access the outlook user profiles through VB.net any help.... thanks in advanc Srinivas
6
by: Manuel | last post by:
Hi, Using the PIA "Microsoft Outlook 11 Object Library". I've noticed that the Logon method of the NameSpace Object is simply ignored. My Outlook 2003 is full updated. For example if I...
1
by: =?Utf-8?B?RWQgUy4=?= | last post by:
I have three Profiles set-up in Outlook (w/XP Pro). In the past, to go from one account to another, all I had to do was X out at the upper right which would take me back to the Profile sign in...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.