跳至内容
菜单
此问题已终结
1 回复
6234 查看

Hi everybody,

I use aeroo to report on .odt, within a loop for I want ti initializze a variable i=0, then it increments in the loop, and in the end I will show the i

It's my idea to catch the value of i in every loop

<i=0>
<for each="oneaddress in o.address">
<i = i + 1>
</for>
<i>

the error :

__filter() got an unexpected keyword argument 'i'

Any idea, thanks

形象
丢弃
最佳答案

If you want to use an autoincrement variable, you can change your for tag with this for tag:

<for each="inc in range(count(objects))">

end call the object in the loop with this one

<objects[inc].name or ''>

when you want show the variable you must only use this tag:

<inc>
形象
丢弃
相关帖文 回复 查看 活动
2
9月 24
11070
1
7月 23
3003
0
7月 22
1617
1
12月 15
3464
0
5月 15
3623