Hi,
Ive created a silverlight report that based on a parameter dynamically adds some report fields in code. So in my NeedsData event on the report definition I check a parameter and create some extra fields and then set the datasource for the report.
This seems to work fine to generate and print the report but when I use the silverlight reportviewer to save as pdf (or any save as format) then it appears I get a new instance of the report on the server (I can set a breakpoint in the constructor) but never get a needsdata event call. I tried moving my code to the constructor but it seems that my parameter is not not initialized yet in the constructor.
Where would be the correct place to dynamically add some report textblocks, etc. in code so that it works for both report generation and save as?
thanks,
Adam
Ive created a silverlight report that based on a parameter dynamically adds some report fields in code. So in my NeedsData event on the report definition I check a parameter and create some extra fields and then set the datasource for the report.
This seems to work fine to generate and print the report but when I use the silverlight reportviewer to save as pdf (or any save as format) then it appears I get a new instance of the report on the server (I can set a breakpoint in the constructor) but never get a needsdata event call. I tried moving my code to the constructor but it seems that my parameter is not not initialized yet in the constructor.
Where would be the correct place to dynamically add some report textblocks, etc. in code so that it works for both report generation and save as?
thanks,
Adam