Quantcast
Channel: Telerik Forums RSS
Viewing all articles
Browse latest Browse all 78072

Displaying programmatically created report in html viewer

$
0
0

Hi,

I have a custom resolver working with my html report viewer to display trdx's just fine. Some reports though are not trdx though so I will create these purely in code (in my resolver?) and pass the report to the viewer. I have tried the code below and it seems to work but I just need to confirm that I am doing it the correct way?

ie. is it correct to return a report object instance from the custom resolver?

publicclassMyResolver : IReportResolver
{
    publicTelerik.Reporting.ReportSource Resolve(stringreport)
    {
        Report rpt = newReport();
 
        ObjectDataSource ods = newObjectDataSource();
        ods.DataSource = GetSomeData();
        rpt.DataSource = ods;
     
    /*
    ...code to set up report items...
    */
             
        returnrpt;
}
 }

 

 


Viewing all articles
Browse latest Browse all 78072


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>