What type of item is an undeliverable email message from the system administrator? 
Author Message
 What type of item is an undeliverable email message from the system administrator?

What type of item is an undeliverable email message from the system
administrator?
I'm cycling through the messages in my inbox and I get a type mismatch error
when it tries to process the system admin item. So if this is not a message
(mailitem)
what is it?

Here's a section of the code I'm using.

Public ns As NameSpace
Public ib As MAPIFolder
Public msg As MailItem

Set ns = ThisOutlookSession.Session
CurrentEmailAddress = ns.CurrentUser.Address
Set ib = ns.GetDefaultFolder(olFolderInbox)

For Each msg In ib.Items
    'Other Code
Next



Mon, 24 Feb 2003 23:28:35 GMT  
 What type of item is an undeliverable email message from the system administrator?

ReportItem.

If you're planning to loop through an Items collection, it's good practice
to declare the object representing an individual item as Object, not a
particular item type.

--
Sue Mosher
Author of
  "Teach Yourself Microsoft Outlook 2000 Programming in 24 Hours"
  "Microsoft Outlook 2000 E-mail and Fax Guide"

Outlook and Exchange solutions at http://www.slipstick.com


Quote:
> What type of item is an undeliverable email message from the system
> administrator?
> I'm cycling through the messages in my inbox and I get a type mismatch
error
> when it tries to process the system admin item. So if this is not a
message
> (mailitem)
> what is it?

> Here's a section of the code I'm using.

> Public ns As NameSpace
> Public ib As MAPIFolder
> Public msg As MailItem

> Set ns = ThisOutlookSession.Session
> CurrentEmailAddress = ns.CurrentUser.Address
> Set ib = ns.GetDefaultFolder(olFolderInbox)

> For Each msg In ib.Items
>     'Other Code
> Next



Tue, 25 Feb 2003 04:01:24 GMT  
 What type of item is an undeliverable email message from the system administrator?

I was able to figure that part out after posting the message.
What I haven't figured out is how to get any data
except the subject lines from the reportitem and
the attached original letter.

I haven't been able to access any recipients or forward the item in any way.
I will have to do something like that since I'm programming for an unmanned
system.
I'm thinking now that I'll send a message to a predetermined user or
distribution list
and move the item to a public folder so the users can investigate.



Quote:
> ReportItem.

> If you're planning to loop through an Items collection, it's good practice
> to declare the object representing an individual item as Object, not a
> particular item type.

> --
> Sue Mosher
> Author of
>   "Teach Yourself Microsoft Outlook 2000 Programming in 24 Hours"
>   "Microsoft Outlook 2000 E-mail and Fax Guide"

> Outlook and Exchange solutions at http://www.slipstick.com



> > What type of item is an undeliverable email message from the system
> > administrator?
> > I'm cycling through the messages in my inbox and I get a type mismatch
> error
> > when it tries to process the system admin item. So if this is not a
> message
> > (mailitem)
> > what is it?

> > Here's a section of the code I'm using.

> > Public ns As NameSpace
> > Public ib As MAPIFolder
> > Public msg As MailItem

> > Set ns = ThisOutlookSession.Session
> > CurrentEmailAddress = ns.CurrentUser.Address
> > Set ib = ns.GetDefaultFolder(olFolderInbox)

> > For Each msg In ib.Items
> >     'Other Code
> > Next



Tue, 25 Feb 2003 05:45:14 GMT  
 What type of item is an undeliverable email message from the system administrator?

ReportItem data is hidden. It doesn't have a Body. You might be able to get
to more of it with CDO, but I don't know anyone whose tried that. The public
folder solution sounds like a good one.

--
Sue Mosher
Author of
  "Teach Yourself Microsoft Outlook 2000 Programming in 24 Hours"
  "Microsoft Outlook 2000 E-mail and Fax Guide"

Outlook and Exchange solutions at http://www.slipstick.com


Quote:
> I was able to figure that part out after posting the message.
> What I haven't figured out is how to get any data
> except the subject lines from the reportitem and
> the attached original letter.

> I haven't been able to access any recipients or forward the item in any
way.
> I will have to do something like that since I'm programming for an
unmanned
> system.
> I'm thinking now that I'll send a message to a predetermined user or
> distribution list
> and move the item to a public folder so the users can investigate.



> > ReportItem.

> > If you're planning to loop through an Items collection, it's good
practice
> > to declare the object representing an individual item as Object, not a
> > particular item type.



> > > What type of item is an undeliverable email message from the system
> > > administrator?
> > > I'm cycling through the messages in my inbox and I get a type mismatch
> > error
> > > when it tries to process the system admin item. So if this is not a
> > message
> > > (mailitem)
> > > what is it?

> > > Here's a section of the code I'm using.

> > > Public ns As NameSpace
> > > Public ib As MAPIFolder
> > > Public msg As MailItem

> > > Set ns = ThisOutlookSession.Session
> > > CurrentEmailAddress = ns.CurrentUser.Address
> > > Set ib = ns.GetDefaultFolder(olFolderInbox)

> > > For Each msg In ib.Items
> > >     'Other Code
> > > Next



Tue, 25 Feb 2003 19:52:27 GMT  
 What type of item is an undeliverable email message from the system administrator?

I believe there's a Microsoft Knowledge Base Article describing how to get
the body either with CDO 1.x or Extended MAPI. Because it's just a matter of
MAPI properties it might be possible to retrieve this info with CDO 1.x but
haven't tried it myself. A search on http://msdn.microsoft.com/support
should bring up some pointers.

--
Siegfried Weber

Microsoft Most Valuable Professional (MVP) - Exchange Server
Co-author of "Professional CDO Programming", Wrox Press 1999

CDOLive - The Premier Resource for Microsoft Collaboration Data Objects
http://www.cdolive.com

Please reply to the newsgroups so that others can benefit from the
discussion.
Questions by e-mail are discarded without further notice - filter active.



Quote:
> ReportItem data is hidden. It doesn't have a Body. You might be able to
get
> to more of it with CDO, but I don't know anyone whose tried that. The
public
> folder solution sounds like a good one.

> --
> Sue Mosher
> Author of
>   "Teach Yourself Microsoft Outlook 2000 Programming in 24 Hours"
>   "Microsoft Outlook 2000 E-mail and Fax Guide"

> Outlook and Exchange solutions at http://www.slipstick.com



> > I was able to figure that part out after posting the message.
> > What I haven't figured out is how to get any data
> > except the subject lines from the reportitem and
> > the attached original letter.

> > I haven't been able to access any recipients or forward the item in any
> way.
> > I will have to do something like that since I'm programming for an
> unmanned
> > system.
> > I'm thinking now that I'll send a message to a predetermined user or
> > distribution list
> > and move the item to a public folder so the users can investigate.



> > > ReportItem.

> > > If you're planning to loop through an Items collection, it's good
> practice
> > > to declare the object representing an individual item as Object, not a
> > > particular item type.



> > > > What type of item is an undeliverable email message from the system
> > > > administrator?
> > > > I'm cycling through the messages in my inbox and I get a type
mismatch
> > > error
> > > > when it tries to process the system admin item. So if this is not a
> > > message
> > > > (mailitem)
> > > > what is it?

> > > > Here's a section of the code I'm using.

> > > > Public ns As NameSpace
> > > > Public ib As MAPIFolder
> > > > Public msg As MailItem

> > > > Set ns = ThisOutlookSession.Session
> > > > CurrentEmailAddress = ns.CurrentUser.Address
> > > > Set ib = ns.GetDefaultFolder(olFolderInbox)

> > > > For Each msg In ib.Items
> > > >     'Other Code
> > > > Next



Tue, 25 Feb 2003 20:57:41 GMT  
 What type of item is an undeliverable email message from the system administrator?
Two things:
1) I was able to forward the reportitem itself as an attachment.
    The orignal message that is supposedly attached to the report
    did not get forwarded.
2) I searched microsoft yesterday and was able to find out very little about
    reportitem. They say that it is an item similar to a mailitem but read
only.
    In their knowledgebase there were messages about the reportitem.body
    returning a  null string. They basicly gave as a solution yeah we know
thats
    a problem but theres no solution. blah . blah . readonly. blah. blah.



Quote:
> I believe there's a Microsoft Knowledge Base Article describing how to get
> the body either with CDO 1.x or Extended MAPI. Because it's just a matter
of
> MAPI properties it might be possible to retrieve this info with CDO 1.x
but
> haven't tried it myself. A search on http://msdn.microsoft.com/support
> should bring up some pointers.

> --
> Siegfried Weber

> Microsoft Most Valuable Professional (MVP) - Exchange Server
> Co-author of "Professional CDO Programming", Wrox Press 1999

> CDOLive - The Premier Resource for Microsoft Collaboration Data Objects
> http://www.cdolive.com

> Please reply to the newsgroups so that others can benefit from the
> discussion.
> Questions by e-mail are discarded without further notice - filter active.



> > ReportItem data is hidden. It doesn't have a Body. You might be able to
> get
> > to more of it with CDO, but I don't know anyone whose tried that. The
> public
> > folder solution sounds like a good one.

> > --
> > Sue Mosher
> > Author of
> >   "Teach Yourself Microsoft Outlook 2000 Programming in 24 Hours"
> >   "Microsoft Outlook 2000 E-mail and Fax Guide"

> > Outlook and Exchange solutions at http://www.slipstick.com



> > > I was able to figure that part out after posting the message.
> > > What I haven't figured out is how to get any data
> > > except the subject lines from the reportitem and
> > > the attached original letter.

> > > I haven't been able to access any recipients or forward the item in
any
> > way.
> > > I will have to do something like that since I'm programming for an
> > unmanned
> > > system.
> > > I'm thinking now that I'll send a message to a predetermined user or
> > > distribution list
> > > and move the item to a public folder so the users can investigate.



> > > > ReportItem.

> > > > If you're planning to loop through an Items collection, it's good
> > practice
> > > > to declare the object representing an individual item as Object, not
a
> > > > particular item type.



> > > > > What type of item is an undeliverable email message from the
system
> > > > > administrator?
> > > > > I'm cycling through the messages in my inbox and I get a type
> mismatch
> > > > error
> > > > > when it tries to process the system admin item. So if this is not
a
> > > > message
> > > > > (mailitem)
> > > > > what is it?

> > > > > Here's a section of the code I'm using.

> > > > > Public ns As NameSpace
> > > > > Public ib As MAPIFolder
> > > > > Public msg As MailItem

> > > > > Set ns = ThisOutlookSession.Session
> > > > > CurrentEmailAddress = ns.CurrentUser.Address
> > > > > Set ib = ns.GetDefaultFolder(olFolderInbox)

> > > > > For Each msg In ib.Items
> > > > >     'Other Code
> > > > > Next



Wed, 26 Feb 2003 06:17:54 GMT  
 What type of item is an undeliverable email message from the system administrator?

OL2000: ReportItem.Body Returns Empty String  at
http://support.microsoft.com/support/kb/articles/Q223/9/06.ASP explains what
I suspected:

"The information stored in the body of the ReportItem is not actually stored
in the PR_BODY MAPI property. Outlook consolidates this information from
various other MAPI properties and displays it in the main portion of the
delivery receipt."

Now all I need is a good little NDR to run MDBvu32.exe against. <g>

--
Sue Mosher
Author of
  "Teach Yourself Microsoft Outlook 2000 Programming in 24 Hours"
  "Microsoft Outlook 2000 E-mail and Fax Guide"

Outlook and Exchange solutions at http://www.slipstick.com



Quote:
> I believe there's a Microsoft Knowledge Base Article describing how to get
> the body either with CDO 1.x or Extended MAPI. Because it's just a matter
of
> MAPI properties it might be possible to retrieve this info with CDO 1.x
but
> haven't tried it myself. A search on http://msdn.microsoft.com/support
> should bring up some pointers.

> --
> Siegfried Weber

> Microsoft Most Valuable Professional (MVP) - Exchange Server
> Co-author of "Professional CDO Programming", Wrox Press 1999

> CDOLive - The Premier Resource for Microsoft Collaboration Data Objects
> http://www.cdolive.com

> Please reply to the newsgroups so that others can benefit from the
> discussion.
> Questions by e-mail are discarded without further notice - filter active.



> > ReportItem data is hidden. It doesn't have a Body. You might be able to
> get
> > to more of it with CDO, but I don't know anyone whose tried that. The
> public
> > folder solution sounds like a good one.



Tue, 11 Mar 2003 03:00:00 GMT  
 
 [ 7 post ] 

 Relevant Pages 

1. Trap undeliverable email message

2. Trap undeliverable email message

3. unwanted emails retruned undeliverable

4. Monitor UnDeliverable Items?

5. Forwarding Undeliverable Messages

6. System Undeliverable

7. Can I access current email message from within email message

8. Removal of attachments on email items in Sent items folder

9. get to message properties of certain email message

10. Explorer-like interface to Outlook items with mixed type items in a folder

11. Messaging Services and their use (not email messaging)

12. run script as administratos

 

 
Powered by phpBB® Forum Software