is ther any way to use binding in format sction ?
sumthing like :
<<[FiledName]:[formatOptions]>>
Can you please provide more details about the specific formatting options and binding you are referring to in your report generation?
Unfortunately, there is no such way. All possible formatting options are described at Outputting Expression Results.
In addition, you can implement a class method providing required formatting based on parameters. After making the corresponding class known by the engine, you can use it in a template. Syntax for this would be like so: <<[Util.Format(FieldName, formatOptions)]>>
.
I have tried to use ToString(and pass the format as parameter, but paramters not passed.
Tostring, called. but with null params.
Passing of parameters is a supported scenario. Have you checked parameter values somehow else? For example, you could try to print them using template syntax like this: <<[formatOptions]>>
.
yes, I Have tried also to pass parmeters as const, its look like overloading (ToString()) not supporting
is it any option to add other extension method to support this?
Overload resolution is also supported by the engine. However, if you try to use extension methods instead of regular overloads, there is one more thing to mention:
Note – Extension methods, other than the built-in ones, can be used only in the form of plain static methods in template expressions.
Source: Using Extension Methods.
If this does not help, please share your sample template, data, and code reproducing the issue for furter analysis on our end.