Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
210
Header and Footer on Child Records are disappearing after a save
posted

I am using an UltraWebGrid on my page to display Employees as a Parent record and the Projects as child rows. Depending on the view the customer wants to see (% or Hours) I turn on or off the % or hour columns on the child records. Everything displays correctly except after a Save function. When I click on the save button to do a Batch update the information gets saved to the database and the page is refreshed but when it comes back all the headers and footers for the Project child records are hidden.

I think it might be that I turn off the % columns in the InitializeRow method because my view is hours and maybe it turns off the headers and footers because I don't check if I am looking at a header or footer row or not.

So how do you determine if the row is a header or footer? Or am I just going down the wrong track. I know using a .Net Datagrid on the databound method I check the following..

 

//Check if we are dealing with an datagrid item not the header or footer
if (e.Item.ItemType == ListItemType.Item || e.Item.ItemType == ListItemType.AlternatingItem)

I don't see anything to check in the RowEventArgs that are passed into the InitializeRow method on the UltraWebGrid.

Any help would be appreicated.