Hard Coding Page Break for Excel export in Crystal 9.0 for Peoplesoft

If I export  directly from CRW to excel my page breaks land where I want to after I ticked off the page break option in the excel export.

However the if the report is running from Peoplesoft Environment and I save as xls the page breaks are not there.  I  would like to know if I can somewhere in the report code   hard code the page breaks to happen in xls.  

You see when it exports in pdf from peoplesoft the page breaks I have set in seciton expert do  work.

Any help would be greatly appreciated.
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.

You can't hard code page breaks but you can have them set too be after a section in the section expert.

So long as you want them after a section is complete you can do hat you want but it should be working in Excel.

BrockAuthor Commented:
Hi Mlmcc:

This is what I have in section expert:
Report Header: free form placement; Suppress (no drill down;
Page Header: nothing set
Page Header a, b, c, d, e, f, g, h -
Group Header #1 - free-form: keep together; suppress blank section
Group Header #2 - free-form; keep together; suppress blank section
Details- free-form placement; keep together; suppress blank section
Group Footer #2 -Free Form Placement; Keep Together; Suppress Blank Section
Group Footer #1 - Free Form Placement; Hide; New Page After; Keep Together; Suppress Blank Section
Page Footer- Free Form Placement; Suppress No Drill Down
Report Footer - Free Form Placement: Suppress No Drill Down

So - the New page after  did not work after footer 1 - I did have one scenario working but I had a lot of space and forgot how I did it.  Also, If I tick the option Create page breaks for each page - this does work but not an option when I run it from the front end of people soft.

Page Header a - is where the main title is  and what I would like to see at the top of the page.

I do believe what you are saying :-) .  I just have never had to examine the pagebreaks for the excel option until this client needed to use it for page breaking.  I did manage to find some code that would do it within a macro but each file created is unique and I would need a macro that references only files with that prefixed name. Unfortunately I don't have time to troubleshoot how to make this reference and the documentation in MS Office does not make this easy to find my answer.

If you have a moment, please examine my section settings....otherwise I will experiment nearer to the end of my day.

Thank you,
Try setting NEW PAGE AFTER for the report header.  That should get your first page header at the top of the page.  The report header runs before the page header.

In CR XI there is an option on the Excel export option popup to insert Excel page breaks for each new page.

There may be a way to set that through the code if you have access to it.



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
BrockAuthor Commented:
Well mlmcc.  I tried and it was not happy.
I do have a soln....
1. Use an existing excel spreadsheet where the macro works, the user will cut and paste values there and perform the operations.

Thank you again,
Lucy :-)
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
Oracle Database

From novice to tech pro — start learning today.