My-FyiReporting
My-FyiReporting copied to clipboard
Pass parameter to instantiated classes
For some reports needing complex calculations we are using (static) classes and pass parameters to them by a method. This is done by using the method as value in a hidden field, which feels a little bit strange.
It would be great to have a way to pass the parameters to this classes while instantiating them. I can think of two approaches:
- Passing a (to be configured) list of parameters to the constructor.
- The classes implement a method
SetParameters(...)
which is called after instantiation.