Tuesday, October 01, 2013

Old tricks sometimes have sharp teeth

There’s an old trick for getting higher resolution images out of PowerPoint.  You add a special key to the registry here:

HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\PowerPoint\Options

For other PowerPoint versions, you'd substitute the appropriate number for 14.0 above ... 15.0 for PPT 2013, 12.0 for PPT 2007, 11.0 for 2003 and so on.  Yep. There's no version 13.0.  And we hear they don't allow black cats on the MS campus either.  Sheesh.

Anyhow ...

The key is a DWORD named ExportBitmapResolution with its value set to the resolution in pixels that you want PowerPoint to produce when you save a presentation as JPG/PNG/etc.   For example, if you set ExportBitmapResolution to 3000, you’ll get images 3000 pixels across instead of the default 960 pixel images when you save your slides as images.

So far, so good.

But it turns out that if you use VBA code or an add-in that exports images and you set the ExportBitmapResolution to a lower value than the code/add-in calls for, you get useless results:  you get a chopped off image of part of the slide in the upper left corner of your image.  The rest of the image is filled with gray or black.  
You get this:
When you should be getting this:



The fix is to delete the registry entry.  Let the code do the work, not the registry.  

There's more about it here, including pictures.