Select all Default Parameter

Posted by: damien.murray on 16 January 2024, 9:31 pm EST

    • Post Options:
    • Link

    Posted 16 January 2024, 9:31 pm EST

    Hi,

    Is it possible to have (Select all) filled in by default on a parameter in ActiveReportsJS. This is a dynamic list so don’t know all the values beforehand.

    Thanks

    Damien

  • Posted 16 January 2024, 9:36 pm EST - Updated 16 January 2024, 9:41 pm EST

  • Posted 17 January 2024, 3:46 pm EST

    Hi Damien,

    You can set values from a DataSet for Parameter Default value. Please refer to the attached sample report and screenshot.

    Select All.zip

  • Posted 17 January 2024, 7:39 pm EST - Updated 17 January 2024, 8:32 pm EST

    Thanks Akshay

    That is exactly what I want and what I had tried but when I try the same code with my dataset I get below message

    [expression evaluator] function StartsWith() not found in Null

    Looking at my issue further it seems to be an issue with passing parameters back to the dataset when I need to have a default value. The parameter values don’t seem to be loaded yet, when I hard code the values back it is fine but I need the parameters to be dynamic as they are being passed from another application

  • Posted 17 January 2024, 10:28 pm EST - Updated 17 January 2024, 10:29 pm EST

    Report_param_pass.zip

    See above example where I pass the end_point back to the datasource. This will work if I do not select a default value

  • Posted 18 January 2024, 6:15 pm EST

    Hi Daimen,

    If you want to fill the Data Source values dynamically I would rather suggest you to bind the Data Source at runtime instead of adding an end_point parameter. Runtime Data Binding

    If you want users to input values for this using UI then you may add an input field in the web page instead of using the Viewer’s parameter panel.

  • Posted 18 January 2024, 9:08 pm EST

    Thanks akshay

    The team had looked at runtime databinding in the past but we had some issues with sub reports. Just to clarify we cannot have a parameter as an endpoint if we want to have select all values prefilled in a parameter?

  • Posted 19 January 2024, 10:23 pm EST

    Is there no way of doing this with a parameter as an end_point? this approach has worked for us except in this scenario

  • Posted 21 January 2024, 7:40 pm EST

    Hi Damien,

    Yes, For cascading parameters it is suggested to use the first parameter in a DataSet and not in a DataSource. For more information, please refer to the following links:

  • Posted 22 January 2024, 8:33 pm EST

    It not that we want to select a subset (cascading parameter) I would like to be able to choose all values by default. If we cannot choose the dataset as a default value without databinding is it possible to choose non queried then Add something like * that would select the (select all) option?

  • Posted 23 January 2024, 10:05 pm EST

    Hi Damien,

    Unfortunately, it is not possible with ActiveReportsJS. It seems the only way to achieve this requirement is to have an external input box for Data URL and use runtime binding option.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels