document.pages is "null"
hi everybody
i'm writing indesign cs6 plugin adobe flash builder/ cs extension builder. hope rightplace ask question.
before wrote couple jacascripts indesign , alwas worked pages document array this:
var test:page = app.activedocument.pages[0];
app indesign application.
now correct number of pages pages.length, there no array pages-objects.
does know what's wrong? api says there schould th collection of pages code.
thanks on this.
best richard
you mixing arrays , collections.
almost sets of dom objects returned collections , not arrays. (some exceptions allpageitems -- or else starts or textconainers.) document.pages collection. iterate through collection should use mycollection.item(index). convert collection array (which might want performance reasons), use mycollection.everyitem().getelements().
hth,
harbs
More discussions in Creative Suite SDK
adobe
Comments
Post a Comment