Count items
Hello Nikita,
Thanks for your reply on my previous post!
How can I use a show an number / amount of items in the current list based on the value of some fields ?
Thank you,
Daniël Pharazijn | IT-department | AG Stedelijk Onderwijs Antwerp Belgium
Thanks for your reply on my previous post!
How can I use a show an number / amount of items in the current list based on the value of some fields ?
Thank you,
Daniël Pharazijn | IT-department | AG Stedelijk Onderwijs Antwerp Belgium
Thank you,
Daniël Pharazijn | IT-department | AG Stedelijk Onderwijs Antwerp Belgium
Daniël Pharazijn | IT-department | AG Stedelijk Onderwijs Antwerp Belgium
- Nikita Kurguzov
- Posts: 889
- Joined: Mon Jul 03, 2017
Hello, Daniël!
The easiest way to do it, would be to add Related Items control to the form, select the same list, All Items view and Show all items from the view. You can also hide it, so it wouldn't show up on the form, by placing this line into Maket -> Style config:
And now you can use this line of JavaScript to get number of items in the list:
Another way to get the number of items would be to send an async request to the list.
The easiest way to do it, would be to add Related Items control to the form, select the same list, All Items view and Show all items from the view. You can also hide it, so it wouldn't show up on the form, by placing this line into Maket -> Style config:
Code: Select all
display: none;
Code: Select all
fd.relatedItems(0).data('ctx').ListData.Row.length;
Cheers
-
- Information
-
Who is online
Users browsing this forum: No registered users and 5 guests