Is there a way to define a <Columns>
outside of a GridView
in my .aspx file such that I can use those <Columns>
in multiple GridView
s in the same page? I have two GridView
s that will have the same DataSource type, just with different content, and I'd rather not repeat all my customized TemplateField
s in each. This seems simple enough, it's just I'm new to ASP.NET. Coming from WPF, it feels like I should be able to define my <Columns>
in some parent "Resources" area, define its TargetType, give it a key, and then reference that key wherever I want those <Columns>
to appear.