Turn off "Export Page Header and Page Footer" via RDC when exporting to Excel

When exporting to Excel via the Report Viewer there is an option "Export Page Header and Page Footer". I want to set this option programatically using the ExportOptions object in the Report Designer Component but there does not seem to be a way to do this. Is there a way to do this?

The reason I want to do this leads me to the real problem. I have a copyright watermark on my report which is implemented in tall Page Header with the Underlay Following Sections option set. This works perfectly in Crystal Viewer but when I export to Excel the copyright image appears on every page and messes up the report. If I can choose not to export the Page Header that solves the problem. If it's not possible to suppress printing of the Page Header is there another way to have a watermark that does't cause this problem?

I'm using Crystal Reports version 9.

Thanks in advance
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

I'm not aware of any direct way to do this.  AFAIK there isn't a way to set this in code and the way you're doing the watermark is the only feasible way I know of.

The only alternative I can think of would be to use a parameter in your report to conditionally suppress the page header section containing the watermark.  You could have your code pass a parameter value that will cause the section containing the watermark to be supressed before doing the export.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
MirsentAuthor Commented:
Thanks, that's a great suggestion. I've tried it and it works perfectly.
Glad to help.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Crystal Reports

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.