Telerik Forums
Reporting Forum
2 answers
151 views

Hello,

How can Angular Report Viewer be localized? I found only this article - https://docs.telerik.com/reporting/html5-report-viewer-localization. But Angular Report Viewer doesn't expose telerikReportViewer variable to the global scope or as module export. Only the ReportViewer constructor function is exported (from telerikReportViewer.js):

module.exports = {
    ReportViewer: telerikReportViewer.ReportViewer
};

And I don't see any way to get access to telerikReportViewer.sr object from application code.

ANDREY
Top achievements
Rank 1
 answered on 28 Sep 2018
3 answers
580 views
I have a picturebox that I am binding to a field on a data item. But if that field is null I want to display a placeholder that is embedded in the report (i.e. as if I had just set the value of the picturebox to an image directly from the explorer). Is this possible? I can't see any way to bind the picture box value to an embedded image as it sets the 'image' property of the picture box in the definition which you can't bind to.
Silviya
Telerik team
 answered on 27 Sep 2018
3 answers
741 views

Hello,

I've just updated to Reporting R3 2018 and I now have an exception when generating a PDF from a report, when a ReportProcessor instance is created. The exception message is the following:

[A]Telerik.Reporting.Configuration.ReportingConfigurationSection cannot be cast to [B]Telerik.Reporting.Configuration.ReportingConfigurationSection. Type A originates from 'Telerik.Reporting, Version=12.1.18.620, Culture=neutral, PublicKeyToken=a9d7983dfcc261be' in the context 'Default' at location 'C:\Temp\Temporary ASP.NET Files\vs\293ea1ac\b0f39161\assembly\dl3\a336f798\0099b611_b108d401\Telerik.Reporting.dll'. Type B originates from 'Telerik.Reporting, Version=12.2.18.912, Culture=neutral, PublicKeyToken=a9d7983dfcc261be' in the context 'Default' at location 'C:\WINDOWS\Microsoft.Net\assembly\GAC_MSIL\Telerik.Reporting\v4.0_12.2.18.912__a9d7983dfcc261be\Telerik.Reporting.dll'.

Unfortunately, the release notes doesn't say anything about a change on this.

Can you please explain what needs to be done to make it work again?

Patrick
Top achievements
Rank 2
Iron
Iron
Iron
 answered on 27 Sep 2018
0 answers
124 views

     I have a sql datasource. The query creates variables such as ( declare @LastYearVal Decimal(28,12) ), and a calculated result is assigned to this variable for further processing later in the query.

When configuring the sql datasource, the parameter @LastYearVal is automatically picked up by the wizard, and I can select the type as "decimal".

Doing so will set @LastYearVal to be Decimal(29,0) at the report run time. (This i could see through the sql profiler)

Due to the variable being Decimal(29,0) instead of Decimal(28,12), it loses decimal points of the calculated result that is getting assigned to it.

Is there a way to configure the sql datasource, so that it sets the above parameter as Decimal(28,12) and can retain the decimal points correctly ?

Nadun
Top achievements
Rank 1
 asked on 27 Sep 2018
13 answers
1.8K+ views
It is true that you can hide panels in a details section, however, the space used in the details section must be as big as everything you have in the section, then if you hide one of the panels, the space already allocated for the panel still shows as white space.

Is there a way to have the section give up it's allotted space if you are hiding a panel?

Thanks,

Philip Carter.

Attached is a screenshot of the design and result


Mark
Top achievements
Rank 2
Bronze
Bronze
Veteran
 answered on 26 Sep 2018
1 answer
231 views

Hi Support,

This problem happens in the Server Report Viewer and also in our application from the upgrade to the Telerik Report 2018.

Look de style generate height: 25.5px . !!!


<div class="trv-report-page" style="height: 25.5px; width: 1146px;">


Example:
Image attach

 

Thank You

Sérgio

Veronika
Telerik team
 answered on 26 Sep 2018
1 answer
321 views

Hi Team,

How to adjust Telerik reporting width automatically fit in 24" inch screen ?

I had go through this link but it was WPF Report https://www.telerik.com/forums/start-report-with-zoom-to-width-as-default.

 

Please help on this.

Ivan Hristov
Telerik team
 answered on 26 Sep 2018
1 answer
796 views

Hi 

I'm using HTML5 report viewer.

According to the following post I should be able to retrieve the current report parameters using this code:

var viewer = $("#reportViewer1").data("telerik_ReportViewer");
 var currentParams = viewer.reportSource().parameters;

 

This method seems to return the last submitted values parameters only and not the 'current' values. For example the default start and end date parameter values in my report depend on another report-type parameter. This works well displaying the required default values in the parameter window. However the code above doesn't return these current values unless the values are actually submitted with "Preview".

Can you suggest a work around to retrieve the current displayed values of each parameter even before they are submitted to Telerik reporting. I already have custom editors and I could attach my own code to monitor the current values - but is there a better recommended way? 

Thanks in advance.

Ian

Todor
Telerik team
 answered on 26 Sep 2018
1 answer
534 views

I am looking for different options to use report viewer in Reactjs Component. Please help if somebody has implemented the same.

 

Silviya
Telerik team
 answered on 26 Sep 2018
6 answers
2.3K+ views
Hi,

I`m using Html Report viewer (R2 2016) integrated in a web application.
I`m experiencing the following problem:

When the application is published (to test or production environment) sometimes the report viewer seems to fail rendering the reports (this does not happen on my Dev environment).
It does not happen all the time, it just happens sometimes.
When the problem occurs the viewer seems to send never ending requests to the Report API controller with the following signature:
~/api/reports/clients/085352-e708/instances/083615-c3d7/documents/085412-2b2a085412-5cbd/info which result with the following json response:
{
"documentReady":false,
"pageCount":0,
"documentMapAvailable":false,
"bookmarkNodes":null
}
No errors, no timeouts just this same json returned saying "documentReady":false.
Once this happens the only way to stop these requests is:
-Restart iis
-Refresh browser
-Delete report viewer cache directory.

If for example I click back button and open the report again, it may be rendered but the requests from the old report continue running.
I`m not sure if the caching behavior has something to do with this but we are using File storage cache with changed default cache directory from "C:\Windows\temp" to internal directory for the Reports web application that is hosted in IIS.
This is the ReportServiceConfiguration object:

new Telerik.Reporting.Services.ReportServiceConfiguration
{
HostAppId = ...,
ReportResolver = ...,
Storage = new FileStorage(HttpContext.Current.Server.MapPath("~/Reports")),
ReportSharingTimeout = 0,
ClientSessionTimeout = 15,
};

I`m attaching a screenshot demonstrating the requests from Google Chrome.

I spent some time investigating the problem with enabled system diagnostics trace listener for the Reporting API.
I observed the following in the log:
If the report is rendered successfully, then the log is just filled with some performance metrics information:
*** ReportProcessor.ProcessReport STARTED ***
*** ProcessReport #0 STARTED ***
*** ReportProcessor.ProcessReport STARTED ***
*** ProcessReport #0 STARTED ***
*** ProcessReport #0 DONE in 00:00:00.5807344 ***
*** ReportProcessor.ProcessReport DONE in 00:00:00.5903065 ***
...

If some error occurs for some reason (bad query, data conversion error, data source discovery/connection problems) it is indicated in the log and the report is rendered showing the error to the user, which is ok:
...
An exception has occurred while processing 'table1' item:
System.Data.SqlClient.SqlException (0x80131904): Conversion failed when converting date and/or time from character string.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
   ...

There are though other errors that occur (for unknown reasons) that don`t seem to stop report from being executed, resulting in endless requests that were previously described.
I managed to catch two of these errors without any explanation why and when they happen (the same report with the same input parameters sometimes fails and sometimes not):

1.
...
An error has occurred while rendering the report: System.Threading.ThreadAbortException: Thread was being aborted.
   at Microsoft.Win32.Win32Native.CreateDirectory(String path, SECURITY_ATTRIBUTES lpSecurityAttributes)
   at System.IO.Directory.InternalCreateDirectory(String fullPath, String path, Object dirSecurityObj, Boolean checkHost)
   at System.IO.Directory.InternalCreateDirectoryHelper(String path, Boolean checkHost)
   at Telerik.Reporting.Cache.File.FileCache.Write(String key, Byte[] bytes)
   at Telerik.Reporting.Cache.CacheStorage.SetBytes(String key, Byte[] value)
   at Telerik.Reporting.Services.Engine.DocumentResources.AddResource(RenderingResource resource)
   at Telerik.Reporting.Services.Engine.Document.AddResource(RenderingResource s)
   at Telerik.Reporting.Services.Engine.RenderingStream.Finish()
   at Telerik.Reporting.Html5Rendering.Writers.ContentOnlyPage.WritePageStyles(String css)
   at Telerik.Reporting.Html5Rendering.Writers.PageBase.WriteEndPage()
   at Telerik.Reporting.Paging.PageCompositionBase.SendPhysicalPages()
   at Telerik.Reporting.Paging.PageCompositionBase.OutputPage()
   at Telerik.Reporting.Paging.PageCompositionBase.CreatePages()
   at Telerik.Reporting.BaseRendering.RenderingExtensionBase.Render(Report report, Hashtable renderingContext, Hashtable deviceInfo, CreateStream createStreamCallback, EvaluateHeaderFooterExpressions evalHeaderFooterCallback)
*** RenderReport #0 DONE in 00:00:00.3681450 ***

2.
...
*** RenderReport #0 STARTED ***
An error has occurred while rendering the report: System.Threading.ThreadAbortException: Thread was being aborted.
   at System.Delegate.DelegateConstruct(Object target, IntPtr slot)
   at Telerik.Reporting.Processing.ElementTreeHelper.GetFirstDescendantsOfType[T](LayoutElement element)
   at Telerik.Reporting.Paging.PagerBase.ResetBookmarkPages(ProcessingElement element)
   at Telerik.Reporting.Paging.PagerBase.ResetBookmarkPages(ProcessingElement element)
   at Telerik.Reporting.Paging.PagerBase.Telerik.Reporting.Paging.IPager.CreatePages(IPageHandler handler, Report report)
   at Telerik.Reporting.BaseRendering.RenderingExtensionBase.Render(Report report, Hashtable renderingContext, Hashtable deviceInfo, CreateStream createStreamCallback, EvaluateHeaderFooterExpressions evalHeaderFooterCallback)
*** RenderReport #0 DONE in 00:00:00.7007492 ***

An error has occurred while rendering the report: System.Threading.ThreadAbortException: Thread was being aborted.
   at Telerik.Reporting.Html5Rendering.CssStyleBuilder.AddBackgroundDeclarations(LayoutElement element)
   at Telerik.Reporting.Html5Rendering.CssStyleBuilder.AddCssStyleFromProcessingElement(LayoutElement element, ElementPageInfo pageInfo)
   at Telerik.Reporting.Html5Rendering.Writers.Html.Element.Begin(LayoutElement element, ElementPageInfo pageInfo)
   at Telerik.Reporting.Html5Rendering.Writers.Report.WriteStartElement(LayoutElement element, ElementPageInfo pageInfo)
   at Telerik.Reporting.Paging.PageElementLayer.AddToPage(IPageHandler handler)
   at Telerik.Reporting.Paging.PageElementManager.AddToPage(IPageHandler handler)
   at Telerik.Reporting.Paging.PageCompositionBase.SendPhysicalPages()
   at Telerik.Reporting.Paging.PageCompositionBase.OutputPage()
   at Telerik.Reporting.Paging.PageCompositionBase.CreatePages()
   at Telerik.Reporting.BaseRendering.RenderingExtensionBase.Render(Report report, Hashtable renderingContext, Hashtable deviceInfo, CreateStream createStreamCallback, EvaluateHeaderFooterExpressions evalHeaderFooterCallback)
*** RenderReport #0 DONE in 00:00:00.7177329 ***



Is there any explanation of this behavior, how can I troubleshoot the reason behind it?
Sainand
Top achievements
Rank 1
 answered on 25 Sep 2018
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?