Converting selected items from a menu into a bullet list

{formmenu: Choice A; default=Choice B; default=Choice C; Choice D; name=menu; multiple=yes}

Option 1a. Join the items with a new line:

{=join(menu, "\n")}

Option 1b. You can join the items with any characters, like a newline and a dash:
{="\n- " & join(menu, "\n- ")}

Option 2a. Use a repeat to have full control of the output for each item and produce a proper bullet list:

  • {item_count=count(menu)}{repeat: for (item, index) in menu}{=item}{if: index < item_count}
  • {endif}{endrepeat}
Option 2b. Same as above but using an ordered list:
  1. {item_count=count(menu)}{repeat: for (item, index) in menu}{=item}{if: index < item_count}
  2. {endif}{endrepeat}

1 Like

I would like to do option 2a. Do I enter the code in the formatter box? What do I actually enter? I keep getting an error message.

You can click the "Copy to Text Blaze" button on the box in the top-right of the embedded box:

This will copy the snippet to your Text Blaze Dashboard. Then you can delete the parts from the snippet that you do not need.

Let me know if it works for you :slightly_smiling_face: