Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

@razor identify last foreach

int iteration=0;
foreach (var item in items)
  {
    iteration++;
    if (iteration < items.Count)
       {
        //do stuff  
       }              
   }
Source by koukej.wordpress.com #
 
PREVIOUS NEXT
Tagged: #identify #foreach
ADD COMMENT
Topic
Name
5+2 =