Select all from list

Is there a way for me to trigger the multiple list to tick all the boxes.

I want a list that will open up sections. If they are not ticked it will give a N/A statement and I want the default to be minimal ticked. But it some cases all will need to be ticked, so rather than having to select them all can I have a single button press?

Sections requiring updated notes - {formmenu: default=1; 2; 3; name=Sections; multiple=yes}

1

{if: includes(Sections,"1")}{formtext}{else}-{endif}

2

{if: includes(Sections,"2")}{formtext}{else}-{endif}

3

{if: includes(Sections,"3")}{formtext}{else}-{endif}

Hi @ryan.holt

How about this:

Sections requiring updated notes - {formtext: name=Sections_count; default=0}

{if: sections_count=0}
N/A
{else}{repeat: for i in seq(1, Sections_count)}
{=i}

{formtext}
{endrepeat}
{endif}

You can change the count of sections you need from the text field.

Thanks,

I simplified the example slightly, so specific sections will pull from another snippet if selected. So it matters which ones are ticked rather than how you have set that example up to add a number.

The sections in reality would be things like - health, occupation, family etc

Okay I see, can you try this then?

{possible_sections=[1, 2, 3]}
Sections requiring updated notes - {formmenu: values={=possible_sections}; name=Sections; multiple=yes} {button: sections= possible_sections; label=Select all}

1

{if: includes(Sections,"1")}{formtext}{else}-{endif}

2

{if: includes(Sections,"2")}{formtext}{else}-{endif}

3

{if: includes(Sections,"3")}{formtext}{else}-{endif}

1 Like

Great thanks I think I have got that to work