The Semi-Rookie Rides again - building a grid in a form

Hi all,

I’ve started another topic on using HTML in a form, but perhaps I should back up a bit and not assume that HTML is the way to go.

I want to construct a form that holds a grid. The grid will be 4 or 5 “boxes” horizontally, by x number of rows depending on the amount of data available to fill it. It could also be something like a 4 by 5 grid on each form, with multiple “pages” created as needed. Each box will have one record’s worth of data, in this case, an image along with some description data. There is a base table along with a couple of related tables that have this data.

The data structure goes something like this. There is a table that holds artwork data. Related to this table are child tables holding the images and other relevant data. The form could be used to display all artwork images, or a filtered list. Picture something like an image gallery on a website, ie, row after row of images from different pictures.

I have built forms containing tabpanels containing rows of records. I’ve also built forms where each iteration of the form holds one records worth of data, along with related child data. This one is kinda new to me.

So far, I haven’t seen an example of a form where one “row” contains data from several different records from the underlying datasource. While trying to design this, I’ve looked at the wiki, at the sample solutions, some Servoy University videos, as well as solutions that might have come up on the forum. I could have easily missed something, but so far I haven’t found anything.

I’ve thought about building the form with multiple tabpanels. I’ve thought about building the form dynamically in some magical way to be determined later :-) As you might expect, it’s one thing to have an idea; figuring out how to implement it is another story.

One suggestion I’ve gotten is to build an HTML table on the form and populate it with data from the records. I can build the table easily (or not so easily) enough, but I’m having difficulty with the syntax for filling the table with data from a foundset. I have seen it done with a dataset, and am wondering if that’s the only way it can be done.

I’ve also had a suggestion to use something like VelocityReports, and build the grid there.

So, I’m looking for some guidance on ways to approach this. As always, any guidance you can provide is greatly appreciated.

Thanks and have a good day.

Ron

Perhaps you can build a “box” form for showing what you want along with the related data and then use the SolutionModel to decide at runtime how many boxes to add depending on the amount of data and the screen size?

Hi Omar,

Thanks for your thoughts.

I ended up being able to do what I needed by using HTML inside the form. Works fine, at least so far :) Varying the size depending on screen size is kind of interesting, tho, and so I’ll take some time to explore what you’re suggesting.

Thanks again and have a good day.

Ron