Thread View: adobe.scripting.indesign
2 messages
2 total messages
Started by matt_p_stone
Wed, 28 Jan 2009 19:27
Relink Data Merge using Find
Author: matt_p_stone
Date: Wed, 28 Jan 2009 19:27
Date: Wed, 28 Jan 2009 19:27
12 lines
1092 bytes
1092 bytes
The script I am using imports XML then merges records. I need the two different input files (even though this seems counter intuitive) because of the groups of people they come from. I want to write a line to find a merge tag and relink it to the source. example: <<new800number>> I can't separate it from the XML because it is part of the layout that will need to flow with changing copy length. I searched the forum but didn't find anything, could someone point me in the right direction? I hope I have supplied enough detail. Many Thanks! -M
Re: Relink Data Merge using Find
Author: matt_p_stone
Date: Wed, 28 Jan 2009 21:18
Date: Wed, 28 Jan 2009 21:18
14 lines
1174 bytes
1174 bytes
So I found a solution. I put the Data Merge line before the import XML line and the XML (though containing info about the merge fields) did not overwrite the input from the Data Merge.
for(myDocumentCounter = app.documents.length; myDocumentCounter > 0; myDocumentCounter--){
app.activeDocument.dataMergeProperties.mergeRecords();
app.activeDocument.importXML(myXML);
Out of curiosity, why?
And would this be the right path toward the original relink question? What would this be missing.
(find text preferences:{find what:"<<a800number>>"}, relink);
Thanks,
-M
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads