如何綁定這個字典網格視圖 -如何綁定字典包含列表,網格視圖
Dictionary<int, Actor> actors = new Dictionary<int, Actor>{
{
1,new Actor
{
ActorId = 1,
ActorName= "Rajanikant",
BirthDate =DateTime.Parse("12-12-1949"),
BirthPlace ="Bangalore",
Photo ="~/Images/1.jpg",
Movies = new List<string>{"Shivaji (2007)","Baba (2002)","ChaalBaaz (1989)"}
}
},
{
2,new Actor
{
ActorId = 2,
ActorName= "Jennifer Aniston",
BirthDate =DateTime.Parse("11-2-1969"),
BirthPlace ="Sherman Oaks",
Photo ="~/Images/2.jpg",
Movies=new List<string>{"Friends (1994)","Bruce Almighty (2003)","Just Go with It (2011)"}
}
},
};
使用C#在asp.net
你也可以標記編程語言嗎? – Kracekumar
你嘗試了什麼? – AbhinavRanjan
它顯示了一些通用的類名在網格視圖綁定 – Shiv