Replace grep replace text partially placed out of endnote's tag

Participant ,
May 13, 2021 May 13, 2021

Copy link to clipboard

Copied

Hi,

I have trying to replace the quote to replace text. In endnote section, the replace text placed out of tag. Kindly guide to place the replace text within the tag. Becuse, If I need to replace again text to quote, wrongly introduced text replaced as below.

 

app.findGrepPreferences.findWhat = "([~}~]])"; 

var myFoundItems =app.documents.item(0).findGrep();

for(var f=0; f<myFoundItems.length; f++){ myFoundItems[f].contents = "[Q1C]" }

 

 

Step 1 

Screenshot 2021-05-13 at 6.59.57 PM.png

Step 2

Screenshot 2021-05-13 at 7.00.50 PM.png

Step 3

Screenshot 2021-05-13 at 7.05.04 PM.png

Step 4

 

Screenshot 2021-05-13 at 7.04.46 PM.png

 

The sample document also place with this post.

 

 

Thanks,

Selva

TOPICS
Scripting

Views

190

Likes

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
Participant ,
May 13, 2021 May 13, 2021

Copy link to clipboard

Copied

Tried too:

app.findGrepPreferences.findWhat = "([~}~]])";

app.changeGrepPreferences.changeTo="[Q1C]";

var myFoundItems =app.documents.item(0).changeGrep();

Likes

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
Participant ,
May 15, 2021 May 15, 2021

Copy link to clipboard

Copied

Hi All,

Have the chance to fix it?

 

 

 

 

Thanks,

Selva

Likes

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
Participant ,
May 17, 2021 May 17, 2021

Copy link to clipboard

Copied

Hi All,

So, I consider to can't avoid this is in endnote section. 

 

 

 

 

Thanks,

Selva

Likes

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
Participant ,
May 17, 2021 May 17, 2021

Copy link to clipboard

Copied

Not attained the solution yet.

Likes

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
Adobe Community Professional ,
May 17, 2021 May 17, 2021

Copy link to clipboard

Copied

Why not MATCH to the quote mark as a Positive Lookahead so that the Found would be inside the quote?

Mike Witherell

Likes

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
Participant ,
May 17, 2021 May 17, 2021

Copy link to clipboard

Copied

LATEST

Hi Mike,

I can try this.

 

Thanks,

Selva

Likes

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