Telerik Forums
Reporting Forum
2 answers
15 views

Hello Team, I'm trying to implement a User Defined Function to be access by Telerik Reports. Is a simple Replace function.

In Report designer I followed the instructions of copying the dll where the report designer is located. It runs fine using the following expression   TelerikFunctions.Telerik_F.Replace("t").

When I try to run it from an API, It does not return anything.

  • I added the TelerikFunctions.dll to the current project where TelerikReporting.dll is located.
  • I added the following entries on the  appsettings.json  
  •  

"configuration": {
"configSections": {
"section": [
{
"_name": "Telerik.Reporting",
"_type": "Telerik.Reporting.Configuration.ReportingConfigurationSection, Telerik.Reporting",
"_allowLocation": "true",
"_allowDefinition": "Everywhere"
},
{
"_name": "Telerik.ReportDesigner",
"_type": "Telerik.ReportDesigner.Configuration.ReportDesignerConfigurationSection, Telerik.ReportDesigner.Configuration",
"_allowLocation": "true",
"_allowDefinition": "Everywhere"
}
]
},
"telerikReporting": {
"assemblyReferences": [
{
"name": "TelerikFunctions",
"version": "1.0.0.0",
"culture": "neutral",
"publicKeyToken": "null"
}
]
}

I also placed the function in the wwwRoot where the reports are located. But still, it doesn't recognize the function.    

Class Library containing UDF

Carlos
Top achievements
Rank 1
Iron
Iron
 answered on 08 May 2024
2 answers
7 views

Hello,

Is there a plan to add the Telerik.ReportViewer.WebForms.dll as a NuGet package as well? I already saw some ReportViewer packages, but not for this one. A local installation of the latest Telerik Reporting provides this dll, but that is not very convenient in automatic deployment and testing. And I'd prefer using official packages instead of  custom packaged dlls.

Thanks!

1 answer
38 views

Hi,

Maybe you want me refer Assign connection string dynamically using report parameter and bindings - Telerik Reporting .I followed the solution, it didn't work . And then I set the 'ConnectionString' to '@ReportParameters.PFDSConnectionString', it also didn't work, even if I add the '.Value'.Pls refer the error.png

But when I set the connection string to the property 'ConnectionString' , it worked. And I tested the parameter rendering, it's also OK. Pls refer the success.png.

I think the C# code is OK. Because when I use the appsetting.json file to injec the connection string.

Set ConnectionString to 'AcosReportsConnection', It's OK too. Pls refer the appsettings.png.

Because now the connection string come from database depending on different input parameters, I need to set the connection string dynamically.

Now I am very confused.

Do you have any suggestiones? Thanks.

 

0 answers
14 views

I use Telerik Reporting Rest Service from Telerik template. I have created a Postgresql source in Report Disigner but I couldnt to connection in TelerikReportRestService.

 

Im using trial version.

1 answer
46 views

hi everybody,

I would like to know if it is possible to have the asp.net mvc generic layout (the one we have when creating a web app) with report, so far I just have report layout.

any suggestion, thanks

Ray

Dimitar
Telerik team
 answered on 09 Feb 2024
0 answers
42 views

Dear community,

I have a license for Telerik_Reporting_R2_2020_SP2_14_1_20_814_DEV, I didn't use reports for long time but I have an application that requires it. I use Visual Studio Community 2022 Version 17.8.6 and tried to re-install report but I still cant find a way to include a trdp file created with Report Designer R2 2020 in my newly created ASP.NET MVC app. I had a look on the internet but still facing this problem.

Is there someone who can guide me to solve this issue.

in advance, many thanks
Ray

Raymond
Top achievements
Rank 1
Veteran
 asked on 06 Feb 2024
1 answer
74 views

I updated my front end package.json to use the Telerik Angular Report Wrapper, and the backend to use Telerik.Reporting 17.2.23.1114 trial:

"@progress/telerik-angular-report-viewer": "^20.23.1114",

 

From the browser, when trying to access the backend `ReportsController` (.Net 4.6), I get the following exception:

<ExceptionMessage>Multiple actions were found that match the request: Formats on type SynWAPI.Controllers.ReportsController GetClientsSessionTimeoutSeconds on type SynWAPI.Controllers.ReportsController Version on type SynWAPI.Controllers.ReportsController</ExceptionMessage>
<ExceptionType>System.InvalidOperationException</ExceptionType>

Now generally when I send a test request to the old version of TelerikReports (14.x) from https://MyApp01.MySite.com/MyApp/api/reports, I get the following response in the browser (however in my upgrade envir it's throwing the above exception):

[{"name":"PDF","localizedName":"Acrobat (PDF) file"},{"name":"CSV","localizedName":"CSV (comma delimited)"},{"name":"XLS","localizedName":"Excel 97-2003"},{"name":"RTF","localizedName":"Rich Text Format"},{"name":"IMAGE","localizedName":"TIFF file"},{"name":"MHTML","localizedName":"Web Archive"},{"name":"XPS","localizedName":"XPS Document"}]

 

In my Angular component html, I'm using the Telerik Wrapper:        

<tr-viewer
    [serviceUrl]="serviceUrl"
    [reportSource]="reportSource"
    [viewMode]="'INTERACTIVE'"
    [scaleMode]="'SPECIFIC'"
    [scale]="1.0"
    [templateUrl]="templateUrl"
>
</tr-viewer>

 

and my `ReportsController` on the backend (.net 4.6)

(based on https://docs.telerik.com/reporting/embedding-reports/host-the-report-engine-remotely/rest-service-report-source-resolver/use-custom-report-source-and-document-resolvers?_ga=2.110664256.43783964.1705943251-1117489418.1701363987&_gl=1*3x39f9*_ga*MTExNzQ4OTQxOC4xNzAxMzYzOTg3*_ga_9JSNBCSF54*MTcwNjExMTg5NC4yMC4xLjE3MDYxMTI5MTMuNDYuMC4w*_gcl_au*NTYzNzA2MTUwLjE3MDEzNjM5ODY. )

using System;
using System.Collections.Generic;
using System.IO;
using System.Web.Http;
using Telerik.Reporting.Cache.Interfaces;
using Telerik.Reporting.Services.WebApi;
using System.Web;
using Telerik.Reporting.Services;
using Telerik.Reporting;

namespace SynWAPI.Controllers
{
    [AllowCrossSiteJson]
    [RoutePrefix("api/reports")]
    public class ReportsController : ReportsControllerBase
    {
        [HttpGet]
        [Route("IsReady")]
        public IHttpActionResult IsReady()
        {
            return Ok("OK Dude !");
        }

        public ReportSource Resolve(string uri, OperationOrigin operationOrigin, IDictionary<string, object> currentParameterValues)
        {
            {
                var appPath = HttpContext.Current.Server.MapPath("~/");
                string reportPath = Path.Combine(appPath, @".\Reports");

                var reportPackager = new ReportPackager();
                Report report = null;
                using (var sourceStream = System.IO.File.OpenRead(reportPath))
                {
                    report = (Report)reportPackager.UnpackageDocument(sourceStream);
                }
               
                return new InstanceReportSource
                {
                    ReportDocument = report
                };
            }
        }
        
        [Obsolete]
        protected override ICache CreateCache()
        {
            return Telerik.Reporting.Services.Engine.CacheFactory.CreateFileCache();
        }
    }
}

 

I can't seem to resolve this issue. Do you have further examples online, or any advice for me here ?

 

thanks,

Bob

 

Bob
Top achievements
Rank 1
Iron
Iron
 updated question on 29 Jan 2024
1 answer
70 views

Hello,

I am trying to install Telerik.Reporting.Services.AspNetCore.Trail in .net 6 application.

Below are the following things that i have done,

  1. Go to Tools > NuGet Package Manager > Package Manager Settings, select Package Manager Sources, and then click the + button.

  2. Enter a Name for the Telerik NuGet feed, for example, telerik.com.

  3. In the Source field, enter https://nuget.telerik.com/v3/index.json and click OK.

 Added the Telerik NuGet feed as a Package source.

 Entered Telerik credentials in the Windows Authentication dialog.

Still i am unable to view Telerik.Reporting.Services.AspNetCore.Trail in package manager.

 

Todor
Telerik team
 answered on 05 Dec 2023
1 answer
38 views

I want to choose which tool in the toolbar should display certain tools. How can I set this up? I'm using backend ASP.NET Core MVC and frontend Angular.

1 answer
504 views

Hello, 

using Telerik.Reporting.17.2.23.1114.nupkg in .Net 8 project leads to warning:

Microsoft.NET.Sdk.targets(284, 5): [NETSDK1206] Found version-specific or distribution-specific runtime identifier(s): alpine-x64. Affected libraries: SQLitePCLRaw.lib.e_sqlite3. In .NET 8.0 and higher, assets for version-specific and distribution-specific runtime identifiers will not be found by default. See https://aka.ms/dotnet/rid-usage for details.

Why it happens is described in MS web site.

I found that Reporting nuget is using old/problematic dependency

<dependency id="SQLitePCLRaw.bundle_green" version="2.0.4" />

If you upgrade this to version 2.1.6, it fixes this problem. See release notes: https://github.com/ericsink/SQLitePCL.raw/releases/tag/v2.1.6

Todor
Telerik team
 answered on 22 Nov 2023
Top users last month
Mark
Top achievements
Rank 1
Yurii
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Hon
Top achievements
Rank 1
Iron
Deltaohm
Top achievements
Rank 3
Bronze
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?