We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

InsertImage scalling error

I’m with some problems with Aspose.Words.

I’m trying to insert an image in my file but my image get streched.

Following the link of this post (http://www.aspose.com/community/forums/145124/image-property-problem/showthread.aspx#145124), I downloaded Aspose.Words .net 9.8.0 dlls from (http://www.aspose.com/community/files/51/.net-components/aspose.words-for-.net/entry297254.aspx) but my problem still the same.

Can anybody help me?

Attached are the PDF file and the original image.

an part of my code:

Document doc = new Document();
builder = new DocumentBuilder(doc);
builder.PageSetup.LeftMargin = 30;
builder.PageSetup.RightMargin = 30;
builder.PageSetup.TopMargin = 30;
builder.PageSetup.BottomMargin = 30;

builder.Writeln();
builder.InsertImage(@“c:\teste.jpg”);

Hi,


Thanks for your inquiry.

Perhaps, you’re using an older version of Aspose.Words; as with Aspose.Words v11.1.0, I was unable to reproduce this issue on my side. I would suggest you please upgrade to the latest version of Aspose.Words i.e. v11.1.0. Moreover, please read the following article on How-to: Migrate to Aspose.Words 10.5 or Higher:
http://docs.aspose.com/display/wordsnet/How+to++Migrate+to+Aspose.Words+10.5+or+Higher

I hope, this will help.

Best Regards,

Hi!
I downloaded Aspose.Words from http://www.aspose.com/community/files/364924/download.aspx now, but the issue stills the same.

See the attached file.

Hi,


Thank you for your inquiry.


Please note that Aspose.Words does nothing with JPEG images upon converting documents to PDF. So, image quality must be the same as in input file. I suppose, you see the difference because PDF reader and MS Word (or other viewers) use different codecs to display the image. To make sure, you can first save your document to DOC/DOCX format and then convert your MS Word document to PDF using MS Word and you will then see that the images looks the same in PDFs produced by Aspose.Words and MS Word.


If we can help you with anything else, please feel free to ask.


Best regards,