AQL langage for writing templates

Hi,
I am new to M2DOc plugin and AQL langage , for writing word templates.
how to identify an element within a collection ?
with the brace , x is the indice ?

regards
Laurent

Hi Laurent,

You can have a look at the working with collections section of the AQL documentation. I’m not sure what you are trying to do. But you can access an element with the at() service with an index from 1 to n:

myCollection->at(1)

Note the ‘->’ operator that pass the all collection to the service (here at()) where the ‘.’ operator would iterate over the collection and pass each element to the service. You can find more details on this in the syntax section.

To help you in the process of writing AQL expressions in the context of your M2Doc template, you can use the M2Doc interpreter view. It provides content assist (CTRL+SPACE) and a rendering of the result.