Initializing help system before first use

Hiding Content when the Result Data is Unavailable

When one or more scenarios have no results data, you can hide the content in portions of your views. This is useful where you are displaying results and comparing multi-scenario views.
To mark a part of a view as dependent on result data, add the vdl-if attribute to the element and set the expression to check the scenario's summaryData.hasResultData property. If you are repeating over all scenarios you can check the summaryData.hasResultData for each scenario, for example:
<vdl-row vdl-repeat="=s in scenarios" vdl-if="=s.summaryData.hasResultData">
    <vdl-column heading="=s.props.name"></vdl-column>
</vdl-row>
If any of the scenarios have no results, you may wish to show a placeholder for that scenario instead of completely omitting that scenario from the view.

The following example loops over all scenarios in the view, creating a section for each. Each section contains a row with a table bound to that scenario and displaying a result entity. This row is only generated for scenarios that have result data. There is an alternative row, containing a "no results" message, for each scenario that is shown when there are no results available for that scenario.

Code editor
<vdl version="5.6">
    <vdl-page>
        <vdl-section vdl-repeat="=s, scenarioIndex in scenarios">
            <vdl-row vdl-if="=s.summaryData.hasResultData">
                <vdl-column>
                    <vdl-table page-mode="paged" page-size="4" scenario="=scenarioIndex">
                        <vdl-table-column entity="Shares_fraction"></vdl-table-column>
                    </vdl-table>
                </vdl-column>
            </vdl-row>
            <vdl-row vdl-if="=!s.summaryData.hasResultData">
                <vdl-column><span vdl-text="No results available. Run the scenario to analyze results."></span></vdl-column>
            </vdl-row>
        </vdl-section>
    </vdl-page>
</vdl>
Hiding Content with no-results

© 2001-2024 Fair Isaac Corporation. All rights reserved. This documentation is the property of Fair Isaac Corporation (“FICO”). Receipt or possession of this documentation does not convey rights to disclose, reproduce, make derivative works, use, or allow others to use it except solely for internal evaluation purposes to determine whether to purchase a license to the software described in this documentation, or as otherwise set forth in a written software license agreement between you and FICO (or a FICO affiliate). Use of this documentation and the software described in it must conform strictly to the foregoing permitted uses, and no other use is permitted.