Solved

Complete Folderpath of Outlook Email

Posted on 2012-03-30
6
528 Views
Last Modified: 2012-03-31
Hi Team,

I tried to search the topic of capturing the complete folder path of the eamils coming up in Outlook, but was not able to find any.

Can someone help me with the same.  What I want to achive is to capture the complete folder path of emails in VBA and then use the same later to open the emails from those paths.

Thanks,
Sandesh.
0
Comment
Question by:Sandesh555
  • 4
  • 2
6 Comments
 
LVL 59

Expert Comment

by:Chris Bottomley
ID: 37790087
Can you explain what you mean by mails coming up ... i.e. when you open an email when you run some code or some particular explanation?

Chris
0
 

Author Comment

by:Sandesh555
ID: 37791368
Hi,

I want to get the complete folder path of the emails in the Inbox.  I have unlimited storage in my Inbox folder so I never move my emails out of this folder.

Now using VBA I want to get the complete folder path and store in an Access database.  Later to be used to open the emails again using VBA.

I hope this answers your question.

Thanks,
Sandesh.
0
 
LVL 59

Accepted Solution

by:
Chris Bottomley earned 500 total points
ID: 37791383
The folder path is:
pstname\Inbox

from
?application.Session.GetDefaultFolder(olFolderInbox).FolderPath

If you are thinking it a DOS folder then you are mistaken.  It is a 'component' within the PST which is MS proprietary.  If you are already aware of this then you may not know that if for a given item you record the entryid for the item in access then you can access the item directly anywhere in VBA\\

Within outlook
?application.ActiveExplorer.Selection(1).entryid
00000000A6B27C64927F1E45934E9F5F3C971BE5C45A2000

IN any VBA application and assuming olkApp points to outlook:
?olkapp.Session.GetItemFromID("00000000A6B27C64927F1E45934E9F5F3C971BE5C45A2000").subject
dbms

Chris
0
Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

 
LVL 59

Expert Comment

by:Chris Bottomley
ID: 37791385
IF I have the wrong idea still then sorry but can you suggest anything to help narrow in on your needs?

Chris
0
 

Author Comment

by:Sandesh555
ID: 37791542
Thanks a lot... It is now working... :)
0
 
LVL 59

Expert Comment

by:Chris Bottomley
ID: 37791681
As an aside, if you check the help it is common practice to explain anything other than 'excellent' as a grade

IN essence as here, unless further question specific clarification is requested and not given then it is not considered good form to mark down the solution since without further knowledge of a deficiency how can the expert help.  

The idea (I believe) is to grade the solution and noting that the grading does not affect your points availability but does help guide others with the same problem then consider if you were (someone else) looking for exactly this same problem would you naturally prefer a second rate 'good' solution over an excellent?

Note my intent here is not to change what has happened but to improve your future relationship with the experts and to try and maintain the overall quality of the solutions in the site since I use it a lot myself in areas where I am less competent.

Please know I am glad to have helped in this instance and I wish you a pleasant experience with the site

Chris
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This process describes the steps required to Import and Export data from and to .pst files using Exchange 2010. We can use these steps to export data from a user to a .pst file, import data back to the same or a different user, or even import data t…
Are you unable to connect or configure Hotmail email account in Microsoft Outlook 2010, 2007? Or Outlook.com emails are not downloading to Outlook? Lets’ see the problem and resolve Outlook Connector error syncing folder hierarchy (0x8004102A).
This Experts Exchange video Micro Tutorial shows how to tell Microsoft Office that a word is NOT spelled correctly. Microsoft Office has a built-in, main dictionary that is shared by Office apps, including Excel, Outlook, PowerPoint, and Word. When …
To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now