• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Bookmark Naming

Engaged ,
May 17, 2021 May 17, 2021

Copy link to clipboard

Copied

Hi All,

 

While I am creating a bookmark with properties name using javascript, name is not updating correctly.

 

myDoc.bookmarks.add(hyperlinkTextDestination, {name: element.contents});

 

naming update on alternate bookmark and "Anchor 1", "Actualy Naming", "Anchor 3", "Actualy Naming", "Anchor 5" and so on....

Capture.PNG

Best Regards,

Sumit

-Sumit
TOPICS
Scripting , SDK

Views

372

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Enthusiast ,
May 23, 2021 May 23, 2021

Copy link to clipboard

Copied

Try it like this:

 

var myBookmark = myDoc.bookmarks.add(hyperlinkTextDestination);
myBookmark.name = element.contents;

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
May 26, 2021 May 26, 2021

Copy link to clipboard

Copied

For this issue, there is one solution.

While adding bookmark store the name of bookmark & bookmark in a multidimensional array.

Once finished creating all the bookmark, then assign name again.

So names will be refreshed.

 

Best

Sunil 

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
May 26, 2021 May 26, 2021

Copy link to clipboard

Copied

I also have faced this issue before 2-3 years. I got out of this issue using the method which I have explained you above.

 

Best

Sunil

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Advocate ,
May 26, 2021 May 26, 2021

Copy link to clipboard

Copied

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jul 18, 2021 Jul 18, 2021

Copy link to clipboard

Copied

LATEST

Hi @Sunil Yadav ,

 

Thanks for your response. 

I stored all the bookmarks specifier to an object with element content and letter rename it.

 

Sumit 

-Sumit

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines