Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Visual Studio.NET / VS Tools for Office / March 2007

Tip: Looking for answers? Try searching our database.

getting items from a public folder

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
HockeyFan - 09 Mar 2007 21:23 GMT
I'm trying to go down through a public folder and look at each mail
item.  It's not working:

           try
           {
               itm =
(Outlook.MailItem)objMyPublicFolder.Items.GetFirst();
           }

This throws an exception:

Unable to cast COM object of type 'System.__ComObject' to interface
type 'Microsoft.Office.Interop.Outlook.MailItem'. This operation
failed because the QueryInterface call on the COM component for the
interface with IID '{00063034-0000-0000-C000-000000000046}' failed due
to the following error: No such interface supported (Exception from
HRESULT: 0x80004002 (E_NOINTERFACE)).

What's the first way to get itsems from a public folder?
Ken Slovak - [MVP - Outlook] - 09 Mar 2007 23:23 GMT
First of all, are objMyPublicFolder and its Items collection valid Outlook
objects? See if you can directly cast them as individual objects.

Second, are the items in that folder, especially the first one, really
MessageClass == "IPM.Note", or could they be some other type of item?

Signature

Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm

> I'm trying to go down through a public folder and look at each mail
> item.  It's not working:
[quoted text clipped - 15 lines]
>
> What's the first way to get itsems from a public folder?

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.