Hi All - Im looking at the KB article: The expression contains undefined function call MyUserFunction() error
http://www.telerik.com/support/kb/reporting/designing-reports/the-expression-contains-undefined-function-call-myuserfunction-error.aspx
excerpt ...
PROBLEM
The following error is thrown when running the report: #ERROR# The expression contains undefined function call MyUserFunction()
SOLUTION
This error can occur in any of these three cases:
In my case I think its #3.
I have a report that uses date ranges to filter data. if a user select a date range that results in zero records, I get the undefined user function error. I assume because of the nulls.
#3 above mentions "Make sure that such cases are handled in the user function" by this assume Telerik means use something to the effect of ..
If (MyParam==null) {return 0;)
I tried this and still get the error, so I must be doing something wrong.
Could someone please test this and report back?
generate a report with a simple UDF. pass a null dataset to the report. Do you get the same error?
http://www.telerik.com/support/kb/reporting/designing-reports/the-expression-contains-undefined-function-call-myuserfunction-error.aspx
excerpt ...
PROBLEM
The following error is thrown when running the report: #ERROR# The expression contains undefined function call MyUserFunction()
SOLUTION
This error can occur in any of these three cases:
- The class library has not been rebuilt and thus the function does not yet exist.
- Using the function with wrong number/type of parameters. The passed fields must match the function signature you've defined originally.
- A field specified as function argument is null. Make sure that such cases are handled in the user function.
In my case I think its #3.
I have a report that uses date ranges to filter data. if a user select a date range that results in zero records, I get the undefined user function error. I assume because of the nulls.
#3 above mentions "Make sure that such cases are handled in the user function" by this assume Telerik means use something to the effect of ..
If (MyParam==null) {return 0;)
I tried this and still get the error, so I must be doing something wrong.
Could someone please test this and report back?
generate a report with a simple UDF. pass a null dataset to the report. Do you get the same error?