When Footer image is added to the excel document it doesn’t scales/alligns according to margins. For more information please see the attached image file. One more thing that i noticed is that the image also gets blur.
I use the following code to add the image in the footer.
Image fImg = Image.FromFile(sFileName);
Bitmap b = new Bitmap(width_pt, height_pt);
using (Graphics g = Graphics.FromImage((Image)b))
g.CompositingQuality = CompositingQuality.HighQuality;
g.SmoothingMode = SmoothingMode.HighQuality;
g.InterpolationMode = InterpolationMode.HighQualityBicubic;
g.PixelOffsetMode = PixelOffsetMode.HighQuality;
g.DrawImage(fImg, 0, 0, width_pt, height_pt);
MemoryStream stream = new MemoryStream();
byte bmpBytes = stream.GetBuffer();
Any help in this regard would be appreciated
PS: If you have any plans of suggesting me to use the latest version then drop it. I already have tested it with no result
Well, to format / scale or set the size of the header/footer picture, you may try some API,
//Get the picture object for the header picture
Aspose.Cells.Picture pic = pageSetup.SetFooterPicture(1, imageData);
//Now use/set pic object’s attribute and methods to scale or size the picture for your need.
// Aspose.Cells.Picture pic = pageSetup.GetPicture(false,1);
//Setting the script for the logo/picture
For blur issue, could you post a sample application, we will check it soon.