foreach (var obj in this.Sizes.Select((sz, i) => new {Size =sz, Index = i }))
{
ViewSize sizeObject = obj.Size;
int currentIndex = obj.Index;
Response.Write("index=" + currentIndex + ": class=" + sizeObject.ClassName);
}
Copyright © 2010 Asif Ashraf's Blog
Icons & Wordpress Theme by N.Design | Blogger Templates by Blog and Web
Nice and really helpful example!!
ReplyDelete