Friday, February 24, 2012

different image source for online and PDF reports?

In my current job, I've inherited a website and some ReportViewer
reports, and I've figured out how to poke around and make some changes
requested by my employer, but there's still a lot that I don't
understand. Any input would be appreciated.
Here's the current problem: the reports that we make available on our
website are mostly made up of images. Up until now, we've been saving
the images at the size that they need to be when the reports are
viewed online at 100%. Of course, this means that when exporting the
report to PDF, or printing it, the quality is unacceptable. I've tried
saving larger images and scaling them proportionately in the reports,
which results in beautiful PDFs and illegible online reports due to
resampling. Naturally, and reasonably, my employer wants our reports
to look good online AND when they're printed. I've looked around
online and found that other people have wrestled with this problem,
with no clear solutions.
The one idea that I've come up with is to use different images for the
online and printed versions (so the online report would use /preview/
image01.png and the PDF would use /print/image01.png or something). Do
you think this is possible? Any idea where I would start?
Thanks in advance for any advice.
SarahOn Jun 4, 2:37 pm, "s. o." <sarah.oh.li...@.gmail.com> wrote:
> In my current job, I've inherited a website and some ReportViewer
> reports, and I've figured out how to poke around and make some changes
> requested by my employer, but there's still a lot that I don't
> understand. Any input would be appreciated.
> Here's the current problem: the reports that we make available on our
> website are mostly made up of images. Up until now, we've been saving
> the images at the size that they need to be when the reports are
> viewed online at 100%. Of course, this means that when exporting the
> report to PDF, or printing it, the quality is unacceptable. I've tried
> saving larger images and scaling them proportionately in the reports,
> which results in beautiful PDFs and illegible online reports due to
> resampling. Naturally, and reasonably, my employer wants our reports
> to look good online AND when they're printed. I've looked around
> online and found that other people have wrestled with this problem,
> with no clear solutions.
> The one idea that I've come up with is to use different images for the
> online and printed versions (so the online report would use /preview/
> image01.png and the PDF would use /print/image01.png or something). Do
> you think this is possible? Any idea where I would start?
> Thanks in advance for any advice.
> Sarah
That sounds like the best option. You should have one report that can
be viewed and then when the user goes to export it, change the report
behind the scenes in the application to point to the smaller imaged
report. This should be fairly straight forward in terms of pointing to
one report in a report viewer and then pointing to another report once
the user selects something like a print preview aspx page or
something. Hope this helps.
Regards,
Enrique Martinez
Sr. Software Consultant

No comments:

Post a Comment