Archos wrote:
> I've created a custom type named person:
>
> function person(name, age) {this.name=name; this.age=age;}
>
> Now, how to create an array (of 10 elements) of that new type?
> [10]person
var persons = [
new person("name 1", 1),
new person("name 2", 2),
new person("name 3", 3),
...
];
Arrays in Javascript don't have a particular type of elements however so
you could freely mix your type with other types in a single array.
--
Martin Honnen --- MVP Data Platform Development
http://msmvps.com/blogs/martin_honnen/