Possible to count only visible rows in repeating group?

I have a repeating group that has rows that display various stock information. Based on dynamic data in each row, I can hide certain rows that do not meet various criteria. This is not a search of a Thing, it is dynamically calculated within the row’s group.

It was works great.

Question: Is it possible to do a :count on only the rows that are visible once others become hidden? When doing a regular count, the number still shows the full list count regardless. Is there a trick to maybe only get the count of the rows that show.

Thanks,
Dan

Hi there, @underhill.dan… just spitballing here, but could you have a custom state that holds the same list as the repeating group, and when a row is hidden, remove the row’s item from the custom state’s list. Then, base your count off of the number of items in the custom state’s list, and you should be good to go.

Anyway, just throwing something out there… hope it helps.

Best…
Mike

1 Like

Hi @mikeloc , that’s actually not a bad idea. I’ll play around with this and see what I can come up with.

The thing with the hiding of my rows, is that they are done completely dynamically based on the data that gets loaded into the row. Various pieces of data in that row are compared and if conditions are met, the visibility of the row is simply turned off. So I’m not sure how removing a row item from a custom state would work because there is no workflow to hide my rows. It’s all done on the fly.

I’m sure there is a solution somewhere, and I’ll see how your idea may work.

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.