General information
Category:
ActiveX controls in VFP
Title:
Read Attachments from Outlook Express Mail
Hi everybody,
I use the MSMAPI activeX to read attachments from Inbox messages:
object.AttachmentCount
(Returns the number of attachments in the message)
then I set the following property:
object.AttachmentIndex
(Sets the currently indexed attachment - its value can range from zero to object.AttachmentCount)
then I read the attachment file from:
object.AttachmentName
The problem is that when the Mapi Client is Outlook Express (or Netscape) the property object.AttachmentCount allways returns zero, although I can still set the object.AttachmentIndex property to the existing attachments and read the respective files.
The only way to find how many attachments the message contains is by trying to set the AttachmentIndex property and catch the error (that fires when that index is beyond the number of attachments in the message).
Does anybody know of a cleaner way to do this ?
I don't want to code my ONERROR routine to catch an error based on its message text.
TIA
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only