How do you create a multi-column datagrid?

Jonathan shared this question 6 years ago
Answered

I have a collection of data in a data master called Albums. There are two fields, Albums.Name (text field) and Albums.Art (a file). I want them displayed in a grid that is 3 columns wide x N rows, where N is "as many as needed." See the attached image for the layout I'm trying to achieve.


So far, everything I do just results in three copies of a 1xN grid, with the data repeated in each column. The web store example Clothes screen seems to do what I want, but I can't figure out how it works.


5b059ca9cafd0c316fed9e9d7e5aabbb

Comments (3)

photo
1

Take a look at this discussion thread https://www.justinmind.com/community.... The trick to have different data on each row is to use the action 'paginate next'

photo
1

Hi Victor,


Unfortunately, that method results in a grid that populates down, then left to right. I need one that goes right to left, then down. I guess maybe I could make that method work by creating a bunch of datagrids that are 1x1. But then I don't have a way to dynamically determine how long the grid should be based on the size of the dataset.


Since this is a very common use case for e-commerce sites, I think this (2 dimensional datagrids) would be a great feature for a future release.

photo
1

You're right, you need to build several 1x1 data grids. I agree a 2 dimensional data grid would be a great feature to add. Thanks for the suggestion!