We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to scale images in essential pdf

Thread ID:

Created:

Updated:

Platform:

Replies:

70549 Dec 14,2007 02:10 PM UTC Dec 18,2007 09:02 AM UTC Windows Forms 1
loading
Tags: PDF
Raghavendar
Asked On December 14, 2007 02:10 PM UTC

Hi I'm trying to scale images to (400 widhth, 250 height). For this I'm using th efollowing code.IPDFImage image= doc1.Graphics.DrawImage(new PointF(0, 0), "C:\\map_sample.jpg");

but I cant set height and width of this image since they are read only properties. Please tele me how to set size of the image.
Thanks


Vinoth Kumar K [Syncfusion]
Replied On December 18, 2007 09:02 AM UTC

Hi Raghu,

Thank you for your interest in Syncfusion Products.

How to set size of the image?

You can set the size of the image by using the below code snippet:

PdfGraphics g = page.Graphics;

//Setting the height, width of the image
g.DrawImage(jpg, 0, 0, 400,250);

Please refer the sample in the below link which illustrates the above:

http://websamples.syncfusion.com/samples/PDF.Windows/F70549/main.htm

Please let me know if you have any other questions.

Regards,
Vinoth



CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;