c# - Reporting services using assembly function with optional parameters -
i have reportingservices report optional integer parameter. parameter nullable. report uses assembly localization , formatting of strings in textboxes. assembly has several overload different parameter types (strings, booleans, etc) problem comes when parameter takes null value, , value passed method of assembly. tried several options:
c# method: public static string method1(string name, int value, string culturename) expression: assemblyname.class1.method1('somestring',parameters!param1.value, 'en') c# method: public static string method1(string name, string culturename, int? value) c# method: public static string method1(string name, string culturename, int? value = null) expression: assemblyname.class1.method1('somestring','en', parameters!param1.value)
and also:
public static string method1(string name, object objectinstance, string culturename) public static string method1(string name, string culturename, object objectinstance = null)
this methods work ok when parameter value other null, when it's null, none of seem work: expression returns "#error" , there's message indicating appropiate overload not found.
how should method declared used when called nullable parameter valued "null"?
thanks in advance.
Comments
Post a Comment