Question T13195
Visible to All Users

Hide panel if no questions within panel are visible

created 2 years ago

Hello:

Is it possible to hide the panel if no questions in the panel are visible (do not meet the Visible If criteria)?

Thanks,
Prashant

Comments (1)

    Hello Prashant,
    A panel is not rendered if it doesn't contain any elements. Please test the following survey JSON:

    JSON
    { "pages": [ { "name": "page1", "elements": [ { "type": "boolean", "name": "question1", "title": "Question Visibility Toggle", "description": "Select Yes to show a Panel with a Question. Select No to hide a Question and a parent Panel.\n" }, { "type": "panel", "name": "panel1", "elements": [ { "type": "text", "name": "question3", "visibleIf": "{question1} = true" } ] } ] } ] }

    Would you please elaborate on your usage scenario?