By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,908 Members | 2,056 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,908 IT Pros & Developers. It's quick & easy.

how do I force CrystalReportViewer to refresh its data?

P: n/a
Bob
I'm asking here because I've posted this question in the crystal newsgroup,
waited two weeks, and got zero response. I would be very appreciative if
someone could shed some light on this problem for me.

I'm using the CrystalDecisions.Windows.Forms.CrystalReportViewer available
in CrystalDecisions.Windows.Forms.dll, version 9.2.3300.0.

Why does the crystal report viewer refuse to reload its data when the
RefreshReport method is called if the report parameters haven't changed? Can
I force it to always refresh or will I have to cobble together an ugly
workaround?

Bob
Nov 21 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Bob
For future reference to others that may find my post, subclassing
ReportDocument and overriding the RefreshReport method is not a viable
option because CrystalReportViewer will not trigger a reload of data if it
sees that the parameters in its ReportDocument haven't changed. You have to
handle the ReportRefresh event (there is no override) in CrystalReportViewer
itself and in it 1. call the refresh method of the report document, 2.
update its parameters, then 3. set CrystalReportViewer's report source to
its report source (no change).

IMHO this is rather clunky, almost smells like a workaround to less than
well-thought-out design. But they refuse to call any behavior a "bug",
probably to keep the $200 I paid them to impart the knowledge I'm sharing
here.

I really dislike Crystal now. I may be stuck with it in my current
deployment but I'm going to looking for other DotNet reporting solutions
(purely DotNet, not this bastardized COM crap) when I have the opportunity.

Bob

"Bob" <no***@nowhere.com> wrote in message
news:uS**************@TK2MSFTNGP11.phx.gbl...
I'm asking here because I've posted this question in the crystal newsgroup, waited two weeks, and got zero response. I would be very appreciative if
someone could shed some light on this problem for me.

I'm using the CrystalDecisions.Windows.Forms.CrystalReportViewer available
in CrystalDecisions.Windows.Forms.dll, version 9.2.3300.0.

Why does the crystal report viewer refuse to reload its data when the
RefreshReport method is called if the report parameters haven't changed? Can I force it to always refresh or will I have to cobble together an ugly
workaround?

Bob

Nov 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Browse more Visual Basic .NET Questions on Bytes