Solved

Opening an attachment

Posted on 1997-04-30
1
648 Views
Last Modified: 2013-12-04
Hi

I'm trying to read a MAPI-attachment with VC4.2
I've read in the help "Opening an Attachment" and it says:

1. Call the message's IMessage::GetAttachmentTable method to access its attachment table.
2. Call HrQueryAllRows to retrieve all rows in the table.
3. For each row:
 a. Open the attachment by passing the attachment number represented in the PR_ATTACH_NUM etc....

What I wonder is how do I get PR_ATTACH_NUM out of the Rows in the table? I have found nothing about this in the helpfiles, nor have I found some sample code.

Hope you can help me

Regards,

Andreas
0
Comment
Question by:cost
1 Comment
 
LVL 1

Accepted Solution

by:
strobert earned 100 total points
ID: 1397048
each row returned by HrQueryAllRows is basically a list of SRow's
(you actually get a SRowSet which has an array of SRow's)

each SRow has an array of SPropValue's (SRow.lpProps)

for each SPropValue, serach for the ulPropTag that is PR_ATTACH_NUM, and the Value piece should have the attach num to pass into OpenAttach.

0

Featured Post

Salesforce Made Easy to Use

On-screen guidance at the moment of need enables you & your employees to focus on the core, you can now boost your adoption rates swiftly and simply with one easy tool.

Question has a verified solution.

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

This article shows a few slightly more advanced techniques for Windows 7 gadget programming, including how to save and restore user settings for your gadget and how to populate the "details" panel that is displayed in the Windows 7 gadget gallery.  …
zlib is a free compression library (a DLL) on which the popular gzip utility is built.  In this article, we'll see how to use the zlib functions to compress and decompress data in memory; that is, without needing to use a temporary file.  We'll be c…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

830 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