In version 4.5.0.7 I am having a problem with images of very similar size displaying extremely differently in the same spreadsheet template. Below is the code I use to display Logo images.
If show_logo = "Y" Then If My.Computer.FileSystem.FileExists(strLogoSmPath) Then lUseImage = True Dim image1 As Bitmap, imgHeight As Integer image1 = New Bitmap(strLogoSmPath) imgHeight = image1.Height ws0.Cells.SetRowHeight(0, imgHeight) ws0.Pictures.Add(0, 0, strLogoSmPath, 100, 100) End If End If
The STW Image displays correctly as it frills up the height of the row as determined by imgHeight.
The IDM image displys at a SMALL fraction of its actual height and width.
I have attached bothe XLS fles and the images. Why is this happenning?
Thank you very much for that education in computer graphics. I have taken the image with pixel resolution of 300 pixels/inch and in an image editor have adjusted to a resolution of 72 and then re-adjusted the height and width. I did not understand the difference between Print rendering of an image and HTML rendering.
It appears that the HTML rendering displays the image according to the stated pixel Width and Height regardless of pixel density (resolution), whereas an Excel file uses the Print method of rendering which takes into account the resolution, resizing the image accordingly, as you have shown.
This Support Forum is the best I have ever seen in terms of responsiveness and technical knowledge.