[Solved] ASP.NET Core 10 Razor Pages: how to use ObjectDatasource where data source is a method returning a ValueTuple

1 Answer 23 Views
.NET Core DataSource Object Report Designer (standalone)
Nitin
Top achievements
Rank 1
Nitin asked on 14 May 2026, 11:44 AM
I have a class representing a SQL Server stored procedure output. The SP returns two datasets. I have a C# method that takes in parameters and runs the SP. It returns a ValueTuple (2 Lists - 1 each for the SP returned dataset). I tried to assign this method as the data source to an ObjectDatasource in the report (using standalone Report Designer); however I get an unexpected error (screenshot attached). Probably, it doesn't support a ValueTuple since if I connect to the class itself then it connects. If this is the case, what is the workaround?

1 Answer, 1 is accepted

Sort by
0
Petar
Telerik team
answered on 19 May 2026, 09:26 AM

Hi Nitin,

Thank you for sharing the screenshot of the observed behavior.

I can confirm that `ValueTuple` is not among the supported types for the ObjectDataSource component; please check Supported object types | ObjectDataSource Component Overview for more information.

As a potential workaround, you may consider creating a wrapper method that returns data in a supported type (for example, `List`). Keep in mind that the ObjectDataSource component supports only a single result set, so you may need to combine the values from the tuple into a single collection.

I also noticed that the data source member expects a `DataService` object as its first parameter, which can be problematic to pass through the designer UI, as it is designed to work with expression-based values. To avoid potential issues, I would recommend simplifying the wrapper method’s parameters (for example, by accepting a string or another easily configurable type instead).

If you continue to experience issues after making this change, I would strongly recommend enabling a trace listener in the Standalone Report Designer, as the generated log file can provide valuable insight into the root cause of the problem (see Troubleshooting Standalone Report Designer).

Regards,
Petar
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tags
.NET Core DataSource Object Report Designer (standalone)
Asked by
Nitin
Top achievements
Rank 1
Answers by
Petar
Telerik team
Share this question
or