User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the JavaScript / DHTML / AJAX section within the Web Development category of DaniWeb, a massive community of 391,969 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 4,141 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our JavaScript / DHTML / AJAX advertiser: Lunarpages Web Hosting
Views: 520 | Replies: 1
Reply
Join Date: Dec 2007
Posts: 52
Reputation: kishou is an unknown quantity at this point 
Rep Power: 1
Solved Threads: 1
kishou kishou is offline Offline
Junior Poster in Training

increment array

  #1  
Apr 1st, 2008
how would i increase the array number?
like array[++0]?
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Nov 2006
Location: South Wales
Posts: 159
Reputation: phper is an unknown quantity at this point 
Rep Power: 2
Solved Threads: 10
phper's Avatar
phper phper is offline Offline
Junior Poster

Re: increment array

  #2  
Apr 1st, 2008
use a "for" statement.

eg:

for(i=0; i<10; i++){
// Do whatever here
}

This code will increment the "i" value by 1 each time until it hits 10 or whatever value specified.

Regards,
Alex.
If you find my post useful please add to my reputation!! Thanks!

ajtrichards web solutions
http://www.ajtrichards.co.uk
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb JavaScript / DHTML / AJAX Marketplace
Thread Tools Display Modes

Similar Threads
Other Threads in the JavaScript / DHTML / AJAX Forum

All times are GMT -4. The time now is 9:20 am.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC