I don't know how to avoid single item lists.
My Word document looks like this:
The bag has the following items:
(a) a pencil;
(b) a toy; and
(c) a lunch box.
I have IF statements running, so not all items (a) - (c) are always displayed. Therefore, it is possible to get:
The bag has the following items:
(a) a pencil.
But I want to present this as:
"The bag has a pencil."
No idea how to do this. Any suggestions? Or is it not possible?
Thank you.
Thanks Aaron.
The REPEAT is a very interesting approach. I'll give it more thought. And explore this.
I didn't use REPEAT because things like "a pencil" are sometimes one sentence, sometimes a massive paragraph. So I've had those sitting in the Word document, with IF statements.
I will also bump into an issue, of nested REPEAT as one of the sentence already relies on a REPEAT. Will weigh it up.
Hey there!
I know this is coming a bit after your question. However, to answer your question:
I think the easiest way to solve a single list issue is just directly inside of the template. Example:
IF COUNT(items) = 0
The bag has no items.
ELSE IF COUNT(items) = 1
The bag has a {{items.Name}}.
ELSE
The bag has REPEAT itemsDialog:a, b and c {{items.Name}} END REPEAT.
END IF
Depending on your use case, you can do the exact same thing inside of a computation variable what has a result type of "Text".
Does that answer your question?
Best,
Aaron Agnello