SitePoint Sponsor |
|
User Tag List
Results 1 to 3 of 3
Thread: for loop condition
Hybrid View
-
Jul 30, 2007, 15:20 #1
- Join Date
- Apr 2006
- Posts
- 89
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
for loop condition
I feel silly asking this but I have had not luck so far in achieving a result.
While the condition is being evaluated in a for loop how would a sub-condition be written that pulls out a specific block of the whole that is being executed.
Say, if one was iterating through 900 or so records and the user only wanted records 50 through 100 one time and maybe another time the user wanted records 325 through 399.
Thanks for any help . . .
-
Jul 30, 2007, 15:42 #2
Well, so you specify different initial value and different value in condition.
Code JavaScript:var start=50; var count=100; for(i=start; i<count; i++)
Saul
-
Jul 31, 2007, 07:09 #3
- Join Date
- Apr 2006
- Posts
- 89
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Thank you daemon . . .
Bookmarks