Baffled...

  • Thread starter Thread starter M Scott S
  • Start date Start date
M

M Scott S

I need to be able to export contact info from Outlook store including the
'notes' field on the contact detail form (the 'memo' type field on the right
hand lower portion where the user can enter as much free form text as they
like...).

The tool I have seems to expose the text of the field w/o trouble.

The problem comes in in that the users have also draggged and dropped
various items in there: emails, docs, xls, whatever, and I need to be able
to pull these out and import them to the target app...

I have been poking around the Outlook Object model, but I can't seem to
figure out the relationship between the 'attachments' and the contacts...

HELP!!!

thanks.
 
Attachments are in the Attachments collection of the ContactItem. You will need to save each attachment as a file before you can do anything with it. Embedded Outlook items are the most difficult to extract; see http://www.outlookcode.com/codedetail.aspx?id=523 for a code sample.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Sue - looking at the code that you mention, it almost looks like embedded
items are not 'safe'...

Having poked through the code I have written, the items that are in fact not
allowing me to export to a file are 'emails' attached to a contact record in
the 'notes' (body) field, they return a class of 5 (olAttachment) and a type
of 5 (OlEmbeddedItem)...

Does this mean that even with Redemption, these items just cannot be pulled
out of Outlook programmatically?

It seemed like the embedded items were the exception in code 523 example...

Thanks!


--
M Scott Schaffernoth
Winnovative
Hudson, NY
(e-mail address removed)
Attachments are in the Attachments collection of the ContactItem. You will
need to save each attachment as a file before you can do anything with it.
Embedded Outlook items are the most difficult to extract; see
http://www.outlookcode.com/codedetail.aspx?id=523 for a code sample.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Sue - looking at the code that you mention, it almost looks like embedded
items are not 'safe'...

Having poked through the code I have written, the items that are in fact not
allowing me to export to a file are 'emails' attached to a contact record in
the 'notes' (body) field, they return a class of 5 (olAttachment) and a type
of 5 (OlEmbeddedItem)...

Does this mean that even with Redemption, these items just cannot be pulled
out of Outlook programmatically?

It seemed like the embedded items were the exception in code 523 example...

Thanks!


--
M Scott Schaffernoth
Winnovative
Hudson, NY
(e-mail address removed)

Attachments are in the Attachments collection of the ContactItem. You will
need to save each attachment as a file before you can do anything with it.
Embedded Outlook items are the most difficult to extract; see
http://www.outlookcode.com/codedetail.aspx?id=523 for a code sample.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
It should be possible to do it with Redemption using the technique demonstrated in the code sample.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Sorry, but it's over my head. I am struggling enough with Outlook's model,
let alone introducing yet another...

I am driving this from access, not outlook.

I don't need code for all the various data types as I am handling that, I
just want to be able to pull out an embedded email msg and save it as a file
to the windows file system...

Is there no way to do that with Outlook's object model? It's simple enough
with the other stuff, what's the magic that makes this such a challenge...?


--
M Scott Schaffernoth
Winnovative
Hudson, NY
(e-mail address removed)

It should be possible to do it with Redemption using the technique
demonstrated in the code sample.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
I thought it had to be straightforward....

I was attempting to save using display name instead of file name...

Duh!


It should be possible to do it with Redemption using the technique
demonstrated in the code sample.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
FileName may not exist for some types of embedded attachments. In that case
DisplayName is about all you can use. If you copy a picture to the clipboard
and paste it into the body of an RTF email there will be no FileName and
accessing it will return an error. That's one example of where FileName is
useless.
 
Correct. There is no way to do that within the Outlook object model.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers


M Scott S said:
Sorry, but it's over my head. I am struggling enough with Outlook's model,
let alone introducing yet another...

I am driving this from access, not outlook.

I don't need code for all the various data types as I am handling that, I
just want to be able to pull out an embedded email msg and save it as a file
to the windows file system...

Is there no way to do that with Outlook's object model? It's simple enough
with the other stuff, what's the magic that makes this such a challenge...?
 
Back
Top