145
rated 0 times
[
149]
[
4]
/ answers: 1 / hits: 33949
/ 11 Years ago, tue, june 25, 2013, 12:00:00
How do I check if I'm on the last iteration of this loop? I'm sorry for asking this question. I'm used to programming in VB.NET and javascript seems very cryptic by nature.
if (QuerySplit.length > 1) {
var NewQuery
for (i=0; i<QuerySplit.length; i++)
{
// if we're not on the last iteration then
if (i != QuerySplit.length) {
// build the new query
NewQuery = QuerySplit[i].value + AND
}
}
}
More From » javascript