I'm using llblgen as my business object layer so all my data comes back in custom objects and collections. I would like to be able to bind the grid to my master level object. This works. I would also like the grid to display an expansion indicator per row (even though it doesn't have the child data yet). When the user clicks to expand a row, I would expect that I can hook that event at the server, determine which row they expanded, load those details from the database for that specific Band0 row, and then populate into that band. If the user clicks another row, then server side, I'd add the child data for that Band0 row. I've been searching this forum and reading the docs and can't find anything even close to what I need. Seems every example uses datasets with multiple tables and load ALL the data, master and detail, from the database upfront and that "loadondemand" is only between the browser and aspnet process.
Does the grid support what I want to do?
Hello,
There is a nice thread about hierarchical UltraWebGrid bound to LLBLGen data object here
http://forums.infragistics.com/forums/p/17590/63948.aspx#63948
You can even find a sample project attached to the first post.
HTH,
Thanks! I've looked that sample over but that sample is relying on the relationship being an easy one and being supplied by LLBL's lazy loading (I think? Or is it loadng all the data upfront still?).
My master object doesn't have a property for loading the details since the relationship is a bit more complex than a simple join. There are external user inputted fields that are also being used to filter the data. I would like to see a sample that populates ONLY the first level of data, shows row expansion indicators for all rows, and then at the server loads the child data on demand from the database whenever the user clicks to expand a row.
I've gotten the grid to a point where I can bind the first band of data and it will show the row expansions indicators per row, but when I click them, it just expands a bunch of empty rows client side, it doesn't post back to the server.
I'm not sure how these events work but you might try the following grid events.
Grid.CollapseRowGrid.ExpandRowGrid.DemandLoad
Also, maybe using the DataBinding event to load your girds datasource with flat data and then call the Grid.DataBind() method in the ExpandRow event. I have no idea if this will work, just trying to give you an things to think about. Good luck!