Skip to content

Commit a674fc7

Browse files
committed
260329-ug: Resolved the given feedback.
1 parent 586e080 commit a674fc7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Document-Processing/PDF/PDF-Library/NET/Working-with-Images.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -752,7 +752,7 @@ using (PdfDocument document = new PdfDocument())
752752
PdfUnitConverter converter = new PdfUnitConverter();
753753

754754
//Convert the image size from pixel to points
755-
SizeF size = converter.ConvertFromPixels(image.PhysicalDimension, PdfGraphicsUnit.Pixel);
755+
SizeF size = converter.ConvertFromPixels(image.PhysicalDimension, PdfGraphicsUnit.Point);
756756

757757
//Set section size based on the image size
758758
section.PageSettings.Size = size;
@@ -798,7 +798,7 @@ using (PdfDocument document = new PdfDocument())
798798
PdfUnitConverter converter = new PdfUnitConverter();
799799

800800
//Convert the image size from pixel to points
801-
SizeF size = converter.ConvertFromPixels(image.PhysicalDimension, PdfGraphicsUnit.Pixel);
801+
SizeF size = converter.ConvertFromPixels(image.PhysicalDimension, PdfGraphicsUnit.Point);
802802

803803
//Set section size based on the image size
804804
section.PageSettings.Size = size;
@@ -845,7 +845,7 @@ Module Program
845845
Dim converter As New PdfUnitConverter()
846846

847847
' Convert image size from pixels to points
848-
Dim size As SizeF = converter.ConvertFromPixels(image.PhysicalDimension, PdfGraphicsUnit.Pixel)
848+
Dim size As SizeF = converter.ConvertFromPixels(image.PhysicalDimension, PdfGraphicsUnit.Point)
849849

850850
' Set section size based on image size
851851
section.PageSettings.Size = size

0 commit comments

Comments
 (0)