Using CSLADataSource for Grid Inside Grid

Using CSLADataSource for Grid Inside Grid

Old forum URL: forums.lhotka.net/forums/t/4884.aspx


m.dobler posted on Thursday, May 22, 2008

Hi all,

I have been using CSLA for a while on the Winforms side and love it. But now I'm forced to jump into the asp.net waggon and build a web site.

I decided to use CSLA 3.5 for my business layer and am just learning how to do so on asp.net. The first issue I have is with boxing a grid view in another grid view (kind of master/child) using CSLADataSource.

What I did is I defined both CSLADataSource controls on the web form binding the master DataSource to my topmost grid and this works fine.

Then I placed my second grid inside the ItemTemplate of a TemplateField of the master grid. Now I use the RowDataBound Event of the master grid to keep track of it's key so I can filter the resulting data in the SelectObject Event of my child CSLADataSource.

The problem now is that it seems that the SelectObject Event of the child data source is raised BEFORE the RowDataBound Event of the master grid.

Am I using it the wrong way? Can I influence the order of events raised?

Thanks for any answer

Mike

Copyright (c) Marimer LLC