Last night I had a customer with a strange problem. Their report ran fine and looked great in preview and when printed. But if it was exported to PDF it had a long line down the page. This didn’t happen if it was printed to a PDF driver so the only time it was visible was when using the CR export function.
I opened the PDF and there was a vertical line on every page, even on blank pages, starting near the top. I opened the RPT and there was no visible object anywhere near the sections at the top where the object should be sitting. I was getting ready to start deleting objects one at a time to see if it was tied to a specific object, but first I decided to check the “Report Explorer”. You can read my last post about the Report Explorer if you are not familiar with it. It is a handy tool.
And in the Report Explorer I found a small box listed in the Report Header where no box was visible. I clicked on the name in the Report Explorer and it highlighted the object on the layout, starting in the Report Header and ending in the Group Header. But even now that I knew where it was, if I clicked off of the object it was completely invisible again. Not even a trace of the box remained visible, which I thought strange. So I checked the “size and position” of this box and found that it had been set to a width of 0.00. Most size settings don’t allow zero, but apparently width is an exception on certain objects. I was able to set the width to zero on boxes, fields and text objects. Fields and text objects are still slightly visible in design mode, even when they are set to a width of zero. Boxes, however, are completely invisible when they have a width of zero. The only time they show up is when you export to PDF.
So the next time you find your PDF exports have an extra vertical line or some other artifact that you can’t explain, check the Report Explorer – or give me a call.