Link to home
Start Free TrialLog in
Avatar of bb3177
bb3177

asked on

Crystal Report page count increases by an increment of the number of pages across debugs?

I am using Crystal Reports in Visual Studio 2005.  I am loading my data via datasets.  I have a 3 page report.  The issue is that every time I open my report in a report viewer, the page count goes up by those 3 pages.  Those 3 added pages are duplicates of the first 3.  When I say open the report, I even mean across debugs.  So even after I close the application and re-run it, I have 3 more pages.  My crystal report is embedded into the application.  The report must be storing the report's state and just appending to it each time.  Is there some sort of way to clear the report?  I tried to load it manually, reset it manually, and I also tried closing the report manualy upon exit via the report's member functions.

  So my page count is now up to 321.  The next time I open it, my page count will be 324 and the 3 added pages will be the same as the first 3.

Any Suggestings?
Avatar of Outin
Outin

First let me say I have no knowledge whatsoever of programming Crystal Reports in Visual Studio 2005 :-)

- Are you sure the problem is in the report, and not in the datasets? E.g. your datasets do not contain more records every time you run the app?
- What about recordcount of your report, does that one increase too? You could put special field 'recordnumber' on your report if you can't find an other way to check that.

--
Outin
Avatar of bb3177

ASKER

Well... I do have many records in my dataset.  I choose the record that I want by passing in a number which is the primary key of the record that I want.  I then set my selection expert to select my record based on that number.  Because of this, the number of records in the dataset should be irrelevant right?

Just to be thourough, the recordset is exactly the same every time.
So I guess the problem is not in the dataset then...
Have you tried adding the recordnumber to the report?
When you add the special field 'record selection formula' to the report, does that one show you what you'd expect?

If the above doesn't lead you to a solution, I'll try to get the attention of some of the other experts...

--
Outin
ASKER CERTIFIED SOLUTION
Avatar of bb3177
bb3177

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
bb3177 solved the problem himself.
No objection to PAQ/Refund

--
Outin