Report Viewer showing result only on first load

0 Answers 42 Views
Report Viewer - Blazor
n/a
Top achievements
Rank 1
n/a asked on 08 Oct 2023, 02:46 PM | edited on 09 Oct 2023, 12:12 PM

Hi

I have a dynamic report viewer in my Blazor solution, when I call the viewer first time it works fine, but when I call different report or same report with different parameter's it load the data but does not show it until i hit refresh button,

 

here is the calling methods of the report

    protected async Task OPEN_REPORT_Onclick()
    {
        ParamsComponent = new Dictionary<string, object>
            {
                { "Params", null },
                { "rptName", "test.trdp" },
                { "OnClosed", EventCallback.Factory.Create(this, OnClosed) }
            };
        TypeComponent = typeof(DynamicReportViewer);
        await js.OpenDialog("report-modal");
    }
    protected async Task OPEN_REPORT2_Onclick()
    {
        ParamsComponent = new Dictionary<string, object>
            {
                { "Params", new Dictionary<string, object>{ {"SH_ID", parameterID } } },
                { "rptName", "Shipment.trdp" },
                { "OnClosed", EventCallback.Factory.Create(this, OnClosed) }
            };
        TypeComponent = typeof(DynamicReportViewer);
        await js.OpenDialog("report-modal");
    }

 

and here is my report viewer

<div class="dashboard">
    <ReportViewer ViewerId="rv1"
                  ServiceUrl="/api/reports"
                  ReportSource="@(new ReportSourceOptions{Report = rptName,Parameters = Params })">
    </ReportViewer>
</div>

 

am I missing something or did something wrong

P.S. when I debug it with breakpoint it works just fine

Update: When Zooming In then Out The data shows up

Update: Problem solved by opening the report in new tab not popup component

No answers yet. Maybe you can help?

Tags
Report Viewer - Blazor
Asked by
n/a
Top achievements
Rank 1
Share this question
or