Script about Dynamic Bookmarks (Parent/Children)


hello!

 

i'm writing 1 script dynamic bookmarks javascript indesing, i'm saying indesign when found "@", create bookmark word before of caracter.

but need write code "parent" first bookmark, , "children" consecutives bookmarks.

 

do know how solve this?

here code:

 

 for(mycounter = 0; mycounter < app.activedocument.stories.length; mycounter++){       mystory = app.activedocument.stories.item(mycounter);       var dato = mystory.paragraphs[0];       var valdato = dato.contents;       var pdato = valdato.substring(valdato.length-1, valdato.length);       if (pdato=="@") {         var h = app.activedocument.hyperlinktextdestinations.add(mystory.paragraphs[0]);         var bm = document.bookmarks.add(h);         bm.name = valdato.substring(0,valdato.length-1);       }   }   

 

thanks,

bert.



More discussions in InDesign


adobe

Comments

Popular posts from this blog

Adobe Reader DC install error 150410

Error: 100600 Update failed, updates have been disabled by your system policy

ReferenceError: Window does not have a constructor : 325