Is there a way in apex to add ‘force.com Content’ files as attachments in emails?

I need to develop a way for users to select what content they want from a custom page and then have it added as an attachment to an email. I know you can add attachments to emails via: http://www.salesforce.com/us/developer/docs/pages/index_Left.htm#CSHID=pages_email_sending_attachments.htm|StartTopic=Content%2Fpages_email_sending_attachments.htm|SkinName=webhelp
But unsure how to access/use the force.com content in this way. Is it even possible? From looking at the object in the schema browser is seems that there is no blob field etc that would allow me to access the content and then send it.

Thanks

Answer

The Content Objects schema should help here. The Blob data exists in the ContentVersion in the VersionData field..

Attribution
Source : Link , Question Author : SalesForceGirl , Answer Author : Daniel Ballinger

Leave a Comment