Telerik Forums
Reporting Forum
1 answer
22 views
Hi all, We have following requirements: 
1. We have an angular application which is going to load .trdp report from report API hosted inside the web app. 
2. These .trdp file have many controls which needs dynamic and custom binding.
3. Data should be pulled from OData API
4. Data pulled from point 3 should be conditionally bind to the different controls in .trdp file in report rest API.

We are facing the following challenges.
1. How to load .trdp file in a programmatic way at the reporting API.
2. How to bind the data to the controls after loading programmatic instance of .trdp report.
3. How to bind the loaded report object in html way in report viewer in Angular.

There are ways to do same in .NET desktop application but how to do same in Web, please advise.

1 answer
27 views
Hi, can we change language of Telerik report preview tool. Like "next page" can be changed to another language.
Dimitar
Telerik team
 answered on 16 Oct 2023
1 answer
18 views

I'm trying in VS2019 the "Telerik Reporting REST Service" project template, however when trying to reach http://localhost:<port>/api/reports
we got the message:

Multiple actions were found that match the request.

Are some suggestions in the forums about how to fix this (none of those worked for me), Besides I would expect an empty project template working.

Any ideas?

 

Thank you.

Momchil
Telerik team
 answered on 16 Oct 2023
1 answer
29 views

Hi,

I would like to use/not use a parameter as a filter depending on the user entered value. If it's 0 then I want to ignore the filter.

Here is my configuration in report designer.

 

Essentially I want to achieve this:

SQL if parameter  aualtranpstper= 0 then 

pst_yer = parameter aualtranpstyer

 

SQL if parameter  aualtranpstper<>0

pst_yer = parameter aualtranpstyer and pst_per = parameter aualtranpstper

 

What should my value column in this screen look like?

I posted the same question after reading here https://www.telerik.com/forums/conditional-filtering-and-to-skip-filter-on-empty-report-parameters#205578 but thought it better to create new question.

Thanks for your help.

 

AW

 

 

 

 


 

 

1 answer
27 views

I have a report which binds to a dataSourceObject1. In that same report, I have a table at the bottom of the report (for something else I need to print along with the report) which binds to dataSourceObject2. However, when I try to print it, the report prints fine until it gets to the table, in which it says,

"An error has occurred while processing Table 'table1': An error has occurred while resolving 'objectDataSource2' data source: Object reference not set to an instance of an object."

Here is what is in my C# code for the data source that the report prints from:

Telerik.Reporting.ObjectDataSource objectDataSource1 = new Telerik.Reporting.ObjectDataSource();

objectDataSource1.DataMember = "PaymentReportResult";
objectDataSource1.DataSource = TransformReport(_paymentData);
objectDataSource1.Parameters.Add(new Telerik.Reporting.ObjectDataSourceParameter("search", typeof(ReportSearch), search));

 

I thought I could do the same with another datasource, adding it in the same way, however this does not work. Additionally, if I switch the dataSource of the table to the same as the report, it also fails. I figured that means I am missing something when it comes to specifically binding it to the table.

Momchil
Telerik team
 answered on 12 Oct 2023
1 answer
18 views

how can i connect to sql server on a azure vm server from telerik stand alone report design with in our network?

 

thanks

Momchil
Telerik team
 answered on 12 Oct 2023
1 answer
41 views

Hello,

I'm trying to run Reporting REST service with docker under Linux environment. I'm using the .NET 6. In my separate Report Viewer application, I see the following error:

Unable to get report parameters. An error has occurred. Type: Telerik.Reporting.ReportSerialization.Current.ReportSerializable`1[Telerik.Reporting.Report]

This is a sample code from my Report Viewer application:

import { TelerikReportViewer } from '@progress/telerik-react-report-viewer'

export default function ReportViewer() {
    let viewer;
    return (
        <TelerikReportViewer
            ref={ e => viewer = e }
            serviceUrl="http://localhost:32788/api/reports/"
            reportSource={{
                report: 'SampleReport.trdp',
                parameters: {}
            }}
            viewerContainerStyle = {{
                position: 'absolute',
                left: '5px',
                right: '5px',
                top: '40px',
                bottom: '5px',
                overflow: 'hidden',
                clear: 'both',
                fontFamily: 'ms sans serif'
            }}
            viewMode="INTERACTIVE"
            scaleMode="SPECIFIC"
            scale={1.0}
            enableAccessibility={false} 
        />
    )
}

And this is my Dockerfile of the REST Service application:

FROM mcr.microsoft.com/dotnet/aspnet:6.0-jammy-amd64 AS base
WORKDIR /app
EXPOSE 80

RUN apt-get update \
    && apt-get install -y --allow-unauthenticated \
        libc6-dev \
        libgdiplus \
        libx11-dev \
    && rm -rf /var/lib/apt/lists/*

FROM mcr.microsoft.com/dotnet/sdk:6.0-jammy-amd64 AS build
WORKDIR /src
RUN dotnet nuget add source https://nuget.telerik.com/v3/index.json -n Telerik -u myemail@ishere.yea -p verysecretpassword --store-password-in-clear-text
COPY ["TelerikReportingRestService/TelerikReportingRestService.csproj", "TelerikReportingRestService/"]
RUN dotnet restore "TelerikReportingRestService/TelerikReportingRestService.csproj"
COPY . .
WORKDIR "/src/TelerikReportingRestService"
RUN dotnet build "TelerikReportingRestService.csproj" -c Release -o /app/build

FROM build AS publish
RUN dotnet publish "TelerikReportingRestService.csproj" -c Release -o /app/publish /p:UseAppHost=false

FROM base AS final
WORKDIR /app
COPY --from=publish /app/publish .

COPY "TelerikReportingRestService/Reports" /app/Reports

ENTRYPOINT ["dotnet", "TelerikReportingRestService.dll"]

Everything works if I deploy it locally on IIS, however, as soon as I deploy with docker, I'm unable to view reports. I also tried to add runtimeconfig.template.json file to my project root folder with the following:

{
  "configProperties": {
    "System.Drawing.EnableUnixSupport": true
  }
}

Without any luck.

The endpoints such as /api/reports/formats and /api/reports/version works fine even with docker:

[{"name":"PDF","localizedName":"Acrobat (PDF) file"},{"name":"CSV","localizedName":"CSV (comma delimited)"},{"name":"XLSX","localizedName":"Excel Worksheet"},{"name":"PPTX","localizedName":"PowerPoint Presentation"},{"name":"RTF","localizedName":"Rich Text Format"},{"name":"IMAGE","localizedName":"TIFF file"},{"name":"DOCX","localizedName":"Word Document"}]
"17.1.23.718"

Any help is appreciated. Thanks

Dimitar
Telerik team
 answered on 12 Oct 2023
1 answer
17 views

Hi support!

We do not have the server version.
We are having the problem that when a technician wants to modify a report made by another technician, he does not let him save the report and he has to save it with another name.

Is there a way to save the report with its name once modified?

This is the message.

We have looked to see if there is any option indicating that the report is blocked, but we have not found anything.

Thanks a lot!

Momchil
Telerik team
 answered on 11 Oct 2023
0 answers
16 views

Hi

I have a dynamic report viewer in my Blazor solution, when I call the viewer first time it works fine, but when I call different report or same report with different parameter's it load the data but does not show it until i hit refresh button,

 

here is the calling methods of the report

    protected async Task OPEN_REPORT_Onclick()
    {
        ParamsComponent = new Dictionary<string, object>
            {
                { "Params", null },
                { "rptName", "test.trdp" },
                { "OnClosed", EventCallback.Factory.Create(this, OnClosed) }
            };
        TypeComponent = typeof(DynamicReportViewer);
        await js.OpenDialog("report-modal");
    }
    protected async Task OPEN_REPORT2_Onclick()
    {
        ParamsComponent = new Dictionary<string, object>
            {
                { "Params", new Dictionary<string, object>{ {"SH_ID", parameterID } } },
                { "rptName", "Shipment.trdp" },
                { "OnClosed", EventCallback.Factory.Create(this, OnClosed) }
            };
        TypeComponent = typeof(DynamicReportViewer);
        await js.OpenDialog("report-modal");
    }

 

and here is my report viewer

<div class="dashboard">
    <ReportViewer ViewerId="rv1"
                  ServiceUrl="/api/reports"
                  ReportSource="@(new ReportSourceOptions{Report = rptName,Parameters = Params })">
    </ReportViewer>
</div>

 

am I missing something or did something wrong

P.S. when I debug it with breakpoint it works just fine

Update: When Zooming In then Out The data shows up

Update: Problem solved by opening the report in new tab not popup component

n/a
Top achievements
Rank 1
 updated question on 09 Oct 2023
1 answer
33 views

I'm facing some issues while connecting my SQL Server using 2 Step Authentication WebServiceDataSource in Telerik Reporting. I have referred the following official documents - Document 1  Document 2

Currently, I'm stuck on a few things:

  1. On Configure Data Retrieval window, Can I leave the Data Selector Field Blank? Is it required to specify JSONPath?
  2. In Postman I don't have to manually add any Headers to my current Authentication and Data Retrieval Endpoint (content type, accept, authorization, etc. these are automatically added by Postman). In Config Request/Authentication Parameters,  do I need to add any of these headers?
  3. In Configure 2 Step Authentication window;
    a. What is the role of Token Path? If it is to retrieve the access_token, as per the documentation is this regex (?:"access_token":")(.?)(?:")* correct? I came up with another regex "access_token":"(.*?)". Let me know which one is correct and why.
    b. What is the Request Body Type? Text or JSON?
  4. Due to the above configuration issues I am getting the following error on the Preview DataSource Results window.
    a. Error- Could not get preview.. An error has occurred. Value cannot be null. Parameter name: content

 

Momchil
Telerik team
 answered on 09 Oct 2023
Top users last month
Abhishek
Top achievements
Rank 1
Iron
Johan
Top achievements
Rank 1
Iron
Mark
Top achievements
Rank 3
Iron
Iron
Iron
Stephan
Top achievements
Rank 2
Iron
Iron
Veteran
Omar
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?