ASP.NET Nested Data Bound Controls
Say I have a Form View with a Repeater inside of it, and then a Data List nested inside of the Repeater. If I had an Update Command in the DataSource for the Form Vi开发者_StackOverflow社区ew would I be able to associate bound values within the Data List to parameters in the Form Views' DS?
You can always go up using .NamingContainer up to the container that has the data you want, and access through .DataItem.
Something around the lines:
((ContainerType)Container.NamingContainer.NamingContainer).DataItem ...
精彩评论