Is there a way to pass a filestream as a parameter

1 Answer 65 Views
Report Parameters
Ed
Top achievements
Rank 1
Iron
Veteran
Iron
Ed asked on 03 Aug 2022, 07:54 AM

I have a report that needs to access files stored on Azure.

What's the best way to do this?

THanks ... Ed

 

1 Answer, 1 is accepted

Sort by
0
Dimitar
Telerik team
answered on 05 Aug 2022, 07:17 AM

Hello Ed,

The Report Parameters cannot accept such value, however, it is possible to access and then use files from Azure storage in the report.

User Functions

One of the ways to use files from Azure storage in your report would be by implementing a user function where you will retrieve those files through C#/VB code and will then return them to be used by the report.

For more details on how to use such functions, please see Extending Reporting Engine with User Functions.

Editing the Report Directly

Other than the user functions approach, you could also unpackage the report definition to get an object instance of the type Telerik.Reporting.Report which you can use to edit any report property directly(including the report items).

If you are using an HTML5-based report viewer, you may do this in a custom implementation of the IReportSourceResolver, for more details, please see the How to use Custom Report Source Resolver and Custom Report Document Resolver article.

Please let me know if you have any other questions.

Regards,
Dimitar
Progress Telerik

Brand new Telerik Reporting course in Virtual Classroom - the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products. Check it out at https://learn.telerik.com/.
Ed
Top achievements
Rank 1
Iron
Veteran
Iron
commented on 05 Aug 2022, 10:41 AM

According to the site you sent me to it says:
The Standalone Report Designer cannot recognize assemblies that target .NET Core/5/6 and higher or .NET Standard 2.1 and higher

So am I dead in the water if I'm using Blazor and .net 6?

 

Dimitar
Telerik team
commented on 08 Aug 2022, 10:46 AM

If the assembly is built for .NET 6, it will indeed not work in the Standalone Report Designer.

Have you considered creating a separate .NET Standard 2.0 class library for the custom functions? Then, you may use that project for both the Standalone Designer and your .NET 6 Blazor app too.

In case you wish to use .NET 6 only, you may consider using our Blazor Web Report Designer widget which does not have the .NET version restrictions. The assembly with the user functions is referenced the same way as ObjectDataSource assemblies, please read the ObjectDataSource Wizard | Telerik Reporting article for the full explanation.

Tags
Report Parameters
Asked by
Ed
Top achievements
Rank 1
Iron
Veteran
Iron
Answers by
Dimitar
Telerik team
Share this question
or