Telerik Forums
Reporting Forum
1 answer
289 views

Hello!

It's used the next version of telerik: Telerik_Reporting_R2_2020_SP1_14_1_20_618

After trying to open the generated html content in the preview mode in different browser the additional pages appeares. In the template all looks good but some unexpected things appeared on the generated html (screenshot was attached):

1. unexpected border (border: 2px solid darkblue;) appeared around the all report content

2. Ctrl+P gets 2 pages but it's expected 1!

3. unexpected css styles appeared in the <head> and a lot of inlined styles appeared at all tags. For instance, the next style at <body> tag  

style="padding-left:57px;padding-right:38px;padding-top:57px;padding-bottom:38px;width:102

gets the mentioned extra page. How it's possible to control the process of generating this styles??

Generated pdf content gets an expected 1 page during the printing.

I attached the template and html rendering result in the archive

Thanks

Todor
Telerik team
 answered on 28 Aug 2023
1 answer
104 views
I can download the data while configuring the data source(API) if I run the report to preview it says not found 404. Not sure what going on here and moreover I'm newbie for Telerik. Please need your help. Thanks 
Todor
Telerik team
 answered on 28 Aug 2023
1 answer
214 views

Hi,

We have a scenario where we need to render the report in multiple worksheets(sheets) within a excel (xlsx) file. We are successful in generating such report when rendered through the desktop client and also in Report Viewer, but when trying to generate the file using  Telerik.Reporting.Processing.ReportProcessor.RenderReport() method, the data is not splitted in to two sheets. Everything is rendered in single sheet.

The way I am rendering the report is simple - 

            var reportProcessor = new Telerik.Reporting.Processing.ReportProcessor();
            var manager = new ReportConnectionStringManager(connectionString);
            ReportSource reportSource = manager.UpdateReportSource(uriReportSource);

            var result = reportProcessor.RenderReport("XLSX", reportSource, null);

and in the report design, we are using SplitWorksheetOnPageBreak property.

 

Please help us in achieving what we want. Is there any other way to render the report.

 

Thanks,

Jyothi

Dimitar
Telerik team
 answered on 24 Aug 2023
1 answer
198 views

Hi every one,

I have to, only show PDF in download list in angular report viewer, I found this list returned from this api

https://docs.telerik.com/reporting/embedding-reports/host-the-report-engine-remotely/rest-api-reference/general-api/get-available-document-formats

I also found answer in

https://www.telerik.com/forums/180100-export-only-in-pdf-format-possible

and to setup Telerik configurations

https://docs.telerik.com/reporting/doc-output/configure-the-report-engine/overview

My question is, I follow above link to setting up Telerik configuration in appsetting.json but still unable to show only PDF as my purpose, does any one have any example of json file or I missed something else.

Thanks and appreciate.

Momchil
Telerik team
 answered on 24 Aug 2023
1 answer
135 views

I want to get the Height of the TextBox on the right of my Vertical Line. I was thinking of using Bindings and Value but I dont know how I can do it.

Momchil
Telerik team
 answered on 24 Aug 2023
1 answer
700 views

Hi,

I have report xml data previously produced with Telerik Windows Designer in my database. That is the xml version of the report.

For example:
<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<Report Width=\"6.5in\" Name=\"test\" xmlns=\"http:// schemas.telerik.com/reporting/2021/1.0\">\r\n <Items>\r\n <PageHeaderSection Height=\"1in\" Name=\"pageHeaderSection1\">\r\n <Items>\ r\n <TextBox Width=\"1.2in\" Height=\"0.2in\" Left=\"2.7in\" Top=\"0.4in\" Value=\"test\" Name=\"textBox1\ " />\r\n </Items>\r\n </PageHeaderSection>\r\n <DetailSection Height=\"2in\" Name=\"detailSection1\" />\r\n <PageFooterSection Height=\ "1in\" Name=\"pageFooterSection1\" />\r\n </Items>\r\n <PageSettings PaperKind=\"Letter\" Landscape=\"False\" ColumnCount=\"1\" ColumnSpacing= \"0in\">\r\n <Margins>\r\n <MarginsU Left=\"1in\" Right=\"1in\" Top=\"1in\" Bottom=\"1in\" />\ r\n </Margins>\r\n </PageSettings>\r\n <StyleSheet>\r\n <StyleRule>\r\n <Style>\r\n <Padding Left=\"2pt\" Right =\"2pt\" />\r\n </Style>\r\n <Selectors>\r\n <TypeSelector Type=\"TextItemBase\" />\r\n <TypeSelector Type=\"HtmlTextBox\ " />\r\n </Selectors>\r\n </StyleRule>\r\n </StyleSheet>\r\n</Report>

I want to be able to design and send such xml content to web report designer.
Converting to json format, deserizale etc. I tried many methods but without success.

Error:
Uncaught (in promise) SyntaxError: Unexpected token '<', "<?xml vers"... is not valid JSON

Some methods I've tried:

var xml = (XmlReportSource)sourceReportSource;
var reportInstance = this.DeserializeReport(xml);
var ss = this.DeserializeReport(xml);

XmlDocument doc = new XmlDocument();
doc.LoadXml(result);
var json = Newtonsoft.Json.JsonConvert.SerializeXmlNode(doc, Newtonsoft.Json.Formatting.None, true);

I would be very happy if you could help with this.
enjoy your work.
1 answer
82 views
buen dia, necesito ayuda, quiero programar un boton para que telerik me mande un reporte periódicamente, pero no se como hacerlo ayudenme porfavor 😞
Dimitar
Telerik team
 answered on 23 Aug 2023
1 answer
898 views

We have many Telerik reports that are fed from SQL Server stored procedures, some of which pull from columns with a type of decimal(38,18) (SQL's max). The system that interacts with these reports uses C# and we limit the values for those columns to 28 significant figures (C#'s max).

 

For example, these values would not be supported by our system:

  • 12,345,678,901.123456789012345678 (11 LHS digits + 18 decimals = 29 total digits)
  • 12,345,678,901,234,567,890.123456789 (20 LHS digits + 9 decimals = 29 total digits)

 

While these would be:

  • 12,345,678,901,234,567,890.12345678 (20 LHS digits + 8 decimals = 28 total digits)
  • 1,234,567,890.123456789012345678 (10 LHS digits + 18 decimals = 28 total digits)

 

We're running into some "Conversion overflows" errors with numbers that have <= 28 significant digits, which after troubleshooting we found to be occurring in Telerik's internal SQL processing, specifically in the System.Data.SqlClient library. Which has this ticket logged: https://github.com/dotnet/SqlClient/issues/95

 

Our system uses Microsoft.Data.SqlClient, which correctly handles truncating trailing zeros.

 

Is there any option for Telerik using the Microsoft.Data.SqlClient library rather than the System.Data.SqlClient library or any other workaround available for this issue? 

 

Here is the full stack trace:

System.OverflowException: Conversion overflows.

   at System.Data.SqlClient.SqlBuffer.get_Decimal()

   at System.Data.SqlClient.SqlBuffer.get_Value()

   at System.Data.SqlClient.SqlDataReader.GetValues(Object[] values)

   at Telerik.Reporting.Processing.Data.SqlDataEnumerable.ReadValues(IDataReader reader)

   at Telerik.Reporting.Processing.Data.SqlDataEnumerable.GetEnumerator()+MoveNext()

   at Telerik.Reporting.Processing.Data.LazyList`1.LazyListEnumerator.MoveNext()

   at System.Collections.Generic.LargeArrayBuilder`1.AddRange(IEnumerable`1 items)

   at System.Collections.Generic.EnumerableHelpers.ToArray[T](IEnumerable`1 source)

   at Telerik.Reporting.Processing.Data.SeedDataAdapter.Execute(IEnumerable`1 data)

   at Telerik.Reporting.Processing.Data.ResultSetAdapter.Execute(IEnumerable`1 data)

   at Telerik.Reporting.Processing.Data.MultidimentionalDataProvider.Execute(MultidimensionalQuery query)

   at Telerik.Reporting.Processing.DataItemResolveDataAlgorithm.GetDataCore(IDataSource dataSource, MultidimensionalQuery query, IServiceProvider serviceProvider, EvalObject expressionContext, IProcessingContext processingContext)

   at Telerik.Reporting.Processing.Report.GetDataCore(IDataSource dataSource, MultidimensionalQuery query)

   at Telerik.Reporting.Processing.DataItemResolveDataAlgorithm.ResolveData(String processingId, InMemoryState inMemoryState, MultidimensionalQuery query, Func`1 getDataCore, EvalObject expressionContext)

   at Telerik.Reporting.Processing.Report.ResolveData()

   at Telerik.Reporting.Processing.Report.ProcessItemCore()

   at Telerik.Reporting.Processing.Report.ProcessItem()

   at Telerik.Reporting.Processing.ReportItemBase.ProcessElement()

   at Telerik.Reporting.Processing.ProcessingElement.Process(IDataMember dataContext)

Dimitar
Telerik team
 answered on 23 Aug 2023
2 answers
258 views

Hi support team,

Currently I have 3 reports called A, B, C with format *.trdp

I used CustomReportResolver to bind datasource for these reports. The problem is I have to use if else condition to know which report is A or B or C to get and bind correct data to the report. Imagine I have 100 reports it will be nightmare for me.

Do we have any way to resolve this or any way to get data source at run time for Standalone Report except the way I described above ?

NOTE: Before I used Visual Studio Report Designer and use NeedDataSource event in each report to get data for them now I have this issue when migrate to Standalone Report Designer.

Example Code:

public ReportSource Resolve(string reportId, OperationOrigin operationOrigin, IDictionary<string, object> currentParameterValues)
{
    var reportPath = Path.Combine(this.ReportsPath, reportId);
    var reportPackager = new ReportPackager();

    Report report = null;
    using (var sourceStream = File.OpenRead(reportPath))
    {
        report = (Report)reportPackager.Unpackage(sourceStream);
    }

    if (reportId == "A")
    {
        if (operationOrigin == OperationOrigin.GenerateReportDocument)
        {
            report.DataSource = GetDataForReportA();
        }        
    }
  else if (reportId == "B")
    {
        if (operationOrigin == OperationOrigin.GenerateReportDocument)
        {
            report.DataSource = GetDataForReportB();
        }        
    }
else if (reportId == "C")
    {
        if (operationOrigin == OperationOrigin.GenerateReportDocument)
        {
            report.DataSource = GetDataForReportC();
        }        
    }

    return new InstanceReportSource
    {
        ReportDocument = report
    };
}


Thanks

Amr
Top achievements
Rank 1
Iron
 updated answer on 23 Aug 2023
2 answers
134 views
I have a report where I define multiple values to be auto-selected in the Report Parameters value Array. All the items in the Array are selected at report run time but one. I can select the one item on the fly, but I cannot figure out why it is not automatically doing it. The string in question is "RA1".  I am adding the report and screenshots.
Michael
Top achievements
Rank 1
Iron
Iron
 updated answer on 21 Aug 2023
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
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?