Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hi can i a create Document object array like this?

Status
Not open for further replies.

daka94

Programmer
Apr 27, 2001
33
US
Document d = new Array[2];
d[0] ="abc.html";
d[1] ="xyz.html";

can i do like this.Please help me.
thanks in advance.
 
var d = new Array()
d[0] ="abc.html";
d[1] ="xyz.html";

yes you can. Another way of writing the same is :

d = ["abc.html","xyz.html"]

Gary Haran
==========================
 
Hi,
Can I write like this.

var doc = new Array();
doc[0]="abc.jsp";
doc[1]="xyz.jsp";
for(var i=0;i < doc.length;i++){
if (doc.getElementById != null){
//do some thing here like reading tags
}
}
thanks in advance
 
Hi,
Can I write like this.

var doc = new Array();
doc[0]=&quot;abc.jsp&quot;;
doc[1]=&quot;xyz.jsp&quot;;
for(var i=0;i < doc.length;i++){
if (doc.getElementById != null){
//do some thing here like reading tags
}
}
thanks in advance

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top