'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Stimulsoft Reports.BLAZOR discussion
mrapi
Posts: 277
Joined: Sat Dec 20, 2008 1:08 am

'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by mrapi »

Hi
I'm trying to display Blazor WebAssembly report in modal just as a report is shown in winforms dialog
for that I use AntDesign modal component and 'Change viewer options' from your git examples
-I've added Antdesign package
- register the service in Program.cs: builder.Services.AddAntDesign();
- added @using AntDesign in _Imports.razor
-added <AntContainer /> in App.razor
-added in wwwroot/index.html <link href="_content/AntDesign/css/ant-design-blazor.css" rel="stylesheet" /> and <script src="_content/AntDesign/js/ant-design-blazor.js"></script>
(steps got from https://antblazor.com/en-US/docs/introduce )

I've attached a sample project,a regular component is shown fine but when I try to show StiBlazorViewer component in Ant modal,the report is show but menus no working and in console got:
'StiJsViewer' was undefined

Code: Select all

blazor.webassembly.js:1 crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
      Unhandled exception rendering component: Could not find 'StiJsViewer.UpdateViewerWebAssembly' ('StiJsViewer' was undefined).
      Error: Could not find 'StiJsViewer.UpdateViewerWebAssembly' ('StiJsViewer' was undefined).
          at http://localhost:50502/_framework/blazor.webassembly.js:1:1287
          at Array.forEach (<anonymous>)
      ....
Microsoft.JSInterop.JSException: Could not find 'StiJsViewer.UpdateViewerWebAssembly' ('StiJsViewer' was undefined).
Error: Could not find 'StiJsViewer.UpdateViewerWebAssembly' ('StiJsViewer' was undefined).
    at http://localhost:50502/_framework/blazor.webassembly.js:1:1287
    at Array.forEach (<anonymous>)
    at e.findFunction (http://localhost:50502/_framework/blazor.webassembly.js:1:1247)
....
Change viewer options.zip
(364 KiB) Downloaded 271 times
thanks
Last edited by mrapi on Fri Jan 28, 2022 6:55 pm, edited 4 times in total.
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by Lech Kulikowski »

Hello,

We need some additional time to investigate the issue, we will let you know about the result.

Thank you.
#3861
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by Lech Kulikowski »

Hello,

We couldn't reproduce the issue. Please check the attached sample.

Thank you.
Attachments
Samples-Blazor-WebAssembly-main.zip
(382.21 KiB) Downloaded 314 times
mrapi
Posts: 277
Joined: Sat Dec 20, 2008 1:08 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by mrapi »

Hi
in your sample there is no report inside a modal as there is in #post1 sample, please recheck it
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by Lech Kulikowski »

Hello,

We need some additional time to investigate the issue, we will let you know about the result.

Thank you.
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by Lech Kulikowski »

Hello,

We still couldn't reproduce the issue. Please provide more detailed information on how to reproduce the issue.

Thank you.
mrapi
Posts: 277
Joined: Sat Dec 20, 2008 1:08 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by mrapi »

Hi,seems I put wrong sample on post#1,now I've updated,please redownload it
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by Lech Kulikowski »

Hello,

Thank you. We will check it and will let you know about the result.
Lech Kulikowski
Posts: 6197
Joined: Tue Mar 20, 2018 5:34 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by Lech Kulikowski »

Hello,

Unfortunately, at the current moment, we couldn't find a solution. There is a task in our to-do list.

Thanky ou.
mrapi
Posts: 277
Joined: Sat Dec 20, 2008 1:08 am

Re: 'StiJsViewer' was undefined when display Blazor WebAssembly report in modal

Post by mrapi »

too bad :(
I'll wait for a fix
Post Reply