Telerik Forums
Reporting Forum
1 answer
107 views

HI

I have written a .NET 8 MVC Application using Telerik Reporting 2025 Q1.
The report works fine when published to local IIS, but fails in a Linux Docker Container:

  http://localhost:8080/Home/Report


Error in browser console : 

Failed to load resource: the server responded with a status of 500 (Internal Server Error) /api/reports/clients/af4ec7bb24c/parameters  report:1
Uncaught (in promise) Invalid report type


HTML5 Report Viewer in View (ReportViewer.cshtml):

  $("#reportViewer1").telerik_ReportViewer({
    serviceUrl: "@Url.Content("~/api/reports/")",
    reportSource: {
        // report: "MyReport.trdp"
        report: "@Model.ReportType.AssemblyQualifiedName",
        parameters: {}
    },

    ...

  });


After trying again and again, I finally found the problem: it's the default image set in PictureBox1.

  Report1.Designer.cs

    this.pictureBox1.Value = ((object)(resources.GetObject("pictureBox1.Value")));

  Report1.resx:

  <assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
  <data name="pictureBox1.Value" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
  <value>
    iVBOR......ggg==
  </value>
</data>


Once I removed the PictureBox, the report viewer worked correctly in the Linux Docker container.


My Questions:

1. Why does the Report Viewer show only a weak message "Invalid report type" ?
.NET 8 no longer supports System.Drawing.Bitmap in Linux Docker Container,
A clearer error message than just 'Invalid report type' would be helpful.

2. Is there any config to enable more detailed error output?
How can PictureBox default images set in the report designer be supported in .NET 8 Linux Docker containers ?

*The /api/reports/formats endpoint works fine.


Environment:

Windows 10 Pro
Visual Studio 2022
.NET 8 (latest)

Docker Container:
Ubuntu 22.04 (VirtualBox)
Docker version 27.5.1

 

Best regards

Chris

2 answers
95 views

Hi,

Are the methods in the ReportsControllerBase that I can use to capture the time taken to render a report and the size of the report?   I want to log all requests for reports with this information.  Using the HTML5 viewer and the WPF viewer.

 

Thanks,

Scott Waye
Top achievements
Rank 2
Iron
Iron
Veteran
 answered on 16 May 2025
1 answer
175 views

Hi,

I'm trying to migrate a project using the legacy WebForms report viewer to html5.

Now our use case requires me to build a report book at runtime, pass different parameters in per report and then add that report to the book. Once I collected all the reports in the book I want to show that specific book in the html5 viewer.

However I'm unsure as to how I can achieve this since the ReportSource doesn't allow me to add the instanciated book in.

Here is a quick example of roughly what I'm trying to do in this case:

Dim rs As New Telerik.ReportViewer.Html5.WebForms.ReportSource()
Dim multiQuoteBook As New Telerik.Reporting.ReportBook()
For Each quoteId In quotes
    Dim localQuoteReport As New Telerik.Reporting.TypeReportSource() 
    localQuoteReport.TypeName = GetType(Reports.QuoteReport).AssemblyQualifiedName
    localQuoteReport.Parameters.Add("LoginEntryId", LoginEntryid)
    localQuoteReport.Parameters.Add("DocumentId", quoteId)
    multiQuoteBook.ReportSources.Add(localQuoteReport)
Next
' How do I assign "multiQuoteBook" to the ReportSource "rs" ?
ReportViewer1.ReportSource = rs

Any input is appreciated.

I found this thread here: ReportBook using HTML5 Viewer in Reporting | Telerik Forums where the dev basically gave up on it as it seemed to hard. It's quite strange that I'm struggling with the same issue.

1 answer
107 views

I'm using Telerik Reporting 2025 Q1 with the standalone Report Designer .NET.

I need to style my reports to match the background color of our application. I thought that using  a Parameter to pass in the color would be a solution, but I can't seem to bind it to the Style.BackgroundColor of the header panel.

I added an Integer parameter called ThemeColor with the value of a hex color (1445712).

First off, there is no editor support for binding for the value of the BackgroundColor (i.e. there is no dropdown menu to select expressions only different color pickets), but I can type in an expression manually. I'm not sure if this indicates that the BackgroundColor doesn't support expressions or it's a quirk of the editor).

I've tried entering =Parameters.ThemeColor, but it says that '=Parameters.ThemeColor is not a valid value for Int32.' 



I've also tried Parameters.ThemeColor.Value, but with the same error.

I've also tried =System.Drawing.Color.FromArgb(Parameters.ThemeColor), but the same error.

It only seems to accept named colors even through the documentation suggests that it should accept hex color.
https://docs.telerik.com/reporting/styling/styling-reports/styling-report-items

Thanks,
Canice

 

Dimitar
Telerik team
 answered on 14 May 2025
0 answers
53 views

Hello,

Few years ago, we have integrated your Web Report Designer into our angular application. However, once we updated to angular 18, when we use production build with aot, Report Designer fails to load with errors like 'Cannot read properties of null'. It works if we disable aot optimization, but that doubles the size of our scripts.

Do you have any advice?

Thank you,

Sergey

Sergey
Top achievements
Rank 1
 asked on 13 May 2025
3 answers
127 views

Hi Team ,

I started using Telerik reporting , not sure how to use Cache mechanism , so telerik report should not connect production database every time instead cache data should be render ?

Tried few things like DatabaseCacheConfigurator.exe , but below error occurs .

Also any file cache mechanism available in Telerik Reporting ? , i can see all Cache mechanism are related to database like SQL Server , Postgre SQL , SQLLite etc....please help on this.

Dess | Tech Support Engineer, Principal
Telerik team
 answered on 09 May 2025
1 answer
113 views

Need assistance in how I can integrate the report viewer in my angular 19 application so I can have users pull up reports from our running Telerik report server.

 

I keep getting this error

Cannot access the Reporting REST service. (serviceUrl = 'http://localhost:81/api/reports'). Make sure the service address is correct and enable CORS if needed. (https://enable-cors.org)

 

I've created a route component for this function (which will be a hyperlink on the client) for pulling up a specific report.

the <task name>.component.html just has the <tr-viewer> element

the <task name>.component.ts has the implementation

Dimitar
Telerik team
 answered on 08 May 2025
1 answer
226 views
Good afternoon.

I'm hitting a new roadblock that I've never hit before with the standalone report viewer.

The crux of the problem - I have many reports with lengthy WITH () statements, none of them have caused issues to date. That said I have a particular data source with this as the second term of the query:

), L01 AS (
    -- L0 without writeoffs
    SELECT * FROM L0 WHERE [WriteoffTF] = 0

That works fine, if I run it alone in SSMS it runs in 7515 ms

I need to make a change based on an output mismatch the client noticed, it's a very simple change - only removing the WHERE clause:

), L01 AS (
    -- L0 without writeoffs
    SELECT * FROM L0 

This query runs alone in SSMS in 8219 ms


In Telerik Standalone Report Viewer the first version works fine but the moment I remove the WITH statement I get this:

Execution Timeout Expired. The timeout period elapsed prior to completion of the operation or the server is not responding.


Where I'm stuck:

1) The connection string is in a .Net Core / Angular project (pulling from the .Net Core side) so there's no web.config until the app is published. The connection string being used is from my appsettings.json file.
2) Adding time to my connection string, like 'Connect Timeout=600', this unfortunately has no impact.

I also tried opening up the .trdp as a .zip and looking at the definition.xml but I couldn't find any reference to time and if I need to add something there I don't have any examples as to what the syntax should be.

I just went to File > Help to see which version of the standalone report viewer I'm using, it's
14.0.20.115.

Please let me know if you have any ideas on how I can resolve this as well as whether you need any additional information.


Ron
Top achievements
Rank 1
Iron
Iron
Iron
 answered on 06 May 2025
1 answer
57 views

I'm using    JsonConvert.SerializeObject(ds)  to convert to JSON string     dataset composed of three tables   the resulting JSONcomes back with something the result shown below.  These fields are part of header section in the report and they are giving me errors.  Someone suggested to remove the square brackets in order to make it work and it did the trick.  Is there a way I can access these fields in the header section without making changes to the resulting JSON?  

Petar
Telerik team
 answered on 05 May 2025
1 answer
95 views
I think I want to do something simple.  I just want to link PictureBox image to a file I uploaded into my Project in Visual Studio.  See screenshot below.

What is the syntax I should use in a UserFunction to link the value of the PictureBox to the image located in the directory indicated below.

Ivet
Telerik team
 answered on 05 May 2025
Top users last month
Top achievements
Rank 1
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ivory
Top achievements
Rank 1
Iron
Nurik
Top achievements
Rank 2
Iron
Iron
YF
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?