0

I am working on a macro to import images (.jpeg) from a folder into Excel. I need high quality documents to be generated from this document. Image Size and Quality settings: Do not compress images in file (not selected).

Comparing two different approaches to import the file:

  1. Insert image into excel file (using Insert tab --> Pictures)
  2. Open the .jpeg file in paint copy and paste into the excel file

Approach (2) results in a much larger size of image than approach (1). The quality of approach (2) is much better. The only problem is that I cannot create a macro to do that. Is there a way to have Excel stop compressing the picture when imported.

I end up saving the file as a XPS file printer (using Zero Losses to the images). Approach (2) matches the source .jpeg image. Approach (1) is just terrible and unusable.

Image size: 2-3 MB

I do not have a macro put together yet. This is just a proof of concept if Excel would be able to meet my image quality requirements.

Any help would be appreciated.

I am using Excel 2013. I saw that Excel 2016 had an option of 'High Fidelity'. Tried to access 2016 on another computer but could not find that option. The max. output is 330 dpi.

Excel MS Support 2016

Community
  • 1
  • 1
M. Marzouk
  • 137
  • 2
  • 15
  • Can you paste the code here so we can see your approaches? Might be a good idea to specify the size of the image in the VBA code when importing – Maldred Oct 20 '17 at 17:12
  • I do not have a macro at this point. If I cannot get the quality that I need out of Excel, we would have to shift over to an Adobe software. So at this point it is only experimental. I am manually inserting the images (Insert tab --> Pictures and locating the image on the hard-drive) versus opening the .jpeg through MS Paint copying and pasting to Excel. Then printing the document the an XPS file and reviewing the quality. As for the size of the image, it is between 2-3 MBs – M. Marzouk Oct 20 '17 at 17:15
  • Check out https://stackoverflow.com/questions/12936646/how-to-insert-a-picture-into-excel-at-a-specified-cell-position-with-vba and to take off image compression try https://support.office.com/en-us/article/Turn-off-picture-compression-81a6b603-0266-4451-b08e-fc1bf58da658 – Maldred Oct 20 '17 at 17:23
  • A quick test to my point: I got a generic image off of google images (searched the word forest and used the first image it found). Pasting from paint the image size is 23.5"x26.78". Inserting through Excel, image size is 7.52"x8.57". The drastic size difference has a huge impact on the # of pixels. – M. Marzouk Oct 20 '17 at 17:24
  • I have the compression de-selected in my file. – M. Marzouk Oct 20 '17 at 17:26

0 Answers0