Suppose I want to bind a generic type (here: Dictionary<string, string>) to a Repeater using the new ASP.NET 4.5 strongly typed data binding.
Then I would have to put down KeyValuePair<string, string> as the ItemType Property of the Repeater.
<asp:Repeater id="rpCategories" runat="server" ItemType="System.Collections.Generic.KeyValuePair<string, string>">
There is an obvious problem here: I can not use < or > within the ItemType text!
How would one go about this? Is the use of generics possible somehow with the new data binding model?
This works for me:
Code behind
Markup