This is a migrated thread and some comments may be shown as answers.

trdx file in report viewer with user function

1 Answer 242 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Bunyamin
Top achievements
Rank 1
Bunyamin asked on 20 Jul 2015, 02:37 AM

Hi,

I've created trdx file with standalone report designer to user function "GetMonth(now.month)" in textbox

I've added report viewer like below code into codebehind onload;

Telerik.Reporting.UriReportSource uriReportSource = new Telerik.Reporting.UriReportSource();
uriReportSource.Uri = "Report1.trdx";
ReportViewer1.ReportSource = uriReportSource;​

and i've added custom function 

  public static object GetMonth(int value)
            {
                return System.Globalization.CultureInfo.CurrentCulture.DateTimeFormat.GetMonthName(value);
            }

 

But it gives below error:

An error has occurred while processing TextBox 'textBox21': The expression contains undefined function call GetMonth(). 

Please help me, how can i call user custom function from trdx file on report viewer?

1 Answer, 1 is accepted

Sort by
0
Stef
Telerik team
answered on 20 Jul 2015, 03:03 PM
Hi Bunyamin,

Please check the settings listed in the Deploying trdx (XML report definition) that uses external assembly KB article.

I hope this information helps you.

Regards,
Stef
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
Bunyamin
Top achievements
Rank 1
Answers by
Stef
Telerik team
Share this question
or