Sharepoint Forum

 
Home » Forum » Sharepoint       Ask a questionRSS Feeds

Converting byte array into PDF content

  Asked By: Aaditya Agrawal         Date: Sep 11, 2009      Category: Sharepoint      Views: 378
 

I am using the following statement in my workflow code to convert my
byte array (Memory stream) into PDF file attachment but I am getting
junk characters when I open the PDF file.

objMail.Attachments.Add(new Attachment(ms, "example.pdf",
"application/pdf"));

When I do the same operation with "application/msword", I am able to
open the attachment in MS Word.

Am I missing any step here? Any help in this would be highly appreciated.


Do you know someone who can help? Share a link to this thread on twitter, or facebook.

Tagged:            

 

No Answers Found. Be the First, To Post Answer.

 
Didn't find what you were looking for? Find more on Converting byte array into PDF content Or get search suggestion and latest updates.


Your Answer
  • Answer should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].