larrystuartjr Posted February 19, 2021 Share Posted February 19, 2021 I think I may be missing something really simple. I have a document where the same text is repeated on many pages. (it's a manual so the name of the client will appear 100 times, for example). I want to use the data merge so that the <company name> text throughout the document is populated with the data from the spreadsheet column/row without having to double click in the fields data merge for every instance. Is this possible? In otherwords, every time <company name> appears in the document the data in column 4 row 4 replaces it. Thanks. Quote Link to comment Share on other sites More sharing options...
Joachim_L Posted February 19, 2021 Share Posted February 19, 2021 Welcome to the Affinity forums @larrystuartjr! Maybe Data Merge is the wrong tool? What about Find and Replace? Somehow the placeholder came already to the text, so why you should need Data Merge? Maybe you are more after variables, which are not supported in the current APu. Quote ------ Windows 10 | i5-8500 CPU | Intel UHD 630 Graphics | 32 GB RAM | Latest Retail and Beta versions of complete Affinity range installed Link to comment Share on other sites More sharing options...
Old Bruce Posted February 19, 2021 Share Posted February 19, 2021 As Joachim_L said if <company name> is already in the text then just search for <company name> and replace with Kodak or ACME Mail Order. Quote Mac Pro (Late 2013) Mac OS 12.7.6 Affinity Designer 2.5.5 | Affinity Photo 2.5.5 | Affinity Publisher 2.5.5 | Beta versions as they appear. I have never mastered color management, period, so I cannot help with that. Link to comment Share on other sites More sharing options...
larrystuartjr Posted February 19, 2021 Author Share Posted February 19, 2021 Thanks for the responses. Yes I could use the find/replace functionality but a lot of the manuals I produce have 100+ different fields that repeat multiple times in the doc. I currently use a web form while on client site to populate the data, export to .csv and then the data replaces all of the placeholders (at least in ID). It takes too long to f/r each one. Affinity Publisher blows ID away but for figuring this one bit of functionality out. sfriedberg 1 Quote Link to comment Share on other sites More sharing options...
sfriedberg Posted February 20, 2021 Share Posted February 20, 2021 @larrystuartjr I know exactly what you are talking about, and at the moment Affinity Publisher doesn't have a good way to handle that. Today's version of Data Merge is targeting things like tickets, or completely repetitive catalog pages, where the merge fields appear once per replacement. Publisher really doesn't support custom (user-defined) fields which you could scatter at will throughout your document, so Data Merge can't integrate with what's not there. The workaround of "just use find/replace" is all the more annoying when you have a bunch of replacements to do, because the Affinity suite find/replace doesn't remember previous substitutions and totally lacks any way of saving/loading a group of substitutions for quick application. Quote Link to comment Share on other sites More sharing options...
mrbips Posted February 20, 2021 Share Posted February 20, 2021 Isn't OP post solved with a simple master page? If exact same text put in the master and apply master to the pages. Quote Link to comment Share on other sites More sharing options...
sfriedberg Posted February 20, 2021 Share Posted February 20, 2021 If the field to be replaced is at fixed locations on the page, then the master page works fine. If the field to be replaced occurs at 100 different places in the text flow, then master pages are of no help whatsoever. You might remember back about 35 years ago, when corporate data processing and customer relationship management had a hybrid child where it was "the thing" to send all your customers these obnoxiously customized sales letters. The writers would find really contorted ways to include your personal name and/or address in the body of the text just so their DP department could print off 100,000 letters each with a customer's first name repeated about six times per page. Fortunately, the fad for that is long over. But there is still a need for long-format documents to have fields replaced throughout the text. Lots and lots of business contracts and legal filings have boilerplate sections that need <Plaintiff> replaced with "John Smith", or <Product> replaced with "Illudium Q-86 Explosive Space Modulator". You do not want to manually walk through a bunch of find/replace operations on this stuff. You want to do exactly what you do for Data Merge: prepare a file with field-value replacements, do your QC and proofreading on the contents of that file, then process the boilerplate base document with the replacements file. Quote Link to comment Share on other sites More sharing options...
MickRose Posted February 20, 2021 Share Posted February 20, 2021 @larrystuartjrI'm pretty sure this can be done. I've attached a spreadsheet file and an afpub file. The afPub file contains a screenshot of the Data Merge Manager dialogue box settings used. The spreadsheet links into the pub file and any one row is selectable and the new content will flow through the document. Although text variables aren't directly supported, this way of doing it seems to be a good workaround. I think you have to be a bit careful with spreadsheet column headings - short & simple is best. Let me know if this is what you want or not. untitled.afpub Book1.xlsx Quote Windows 10 Pro, I5 3.3G PC 16G RAM Link to comment Share on other sites More sharing options...
larrystuartjr Posted February 20, 2021 Author Share Posted February 20, 2021 10 hours ago, sfriedberg said: If the field to be replaced is at fixed locations on the page, then the master page works fine. If the field to be replaced occurs at 100 different places in the text flow, then master pages are of no help whatsoever. You might remember back about 35 years ago, when corporate data processing and customer relationship management had a hybrid child where it was "the thing" to send all your customers these obnoxiously customized sales letters. The writers would find really contorted ways to include your personal name and/or address in the body of the text just so their DP department could print off 100,000 letters each with a customer's first name repeated about six times per page. Fortunately, the fad for that is long over. But there is still a need for long-format documents to have fields replaced throughout the text. Lots and lots of business contracts and legal filings have boilerplate sections that need <Plaintiff> replaced with "John Smith", or <Product> replaced with "Illudium Q-86 Explosive Space Modulator". You do not want to manually walk through a bunch of find/replace operations on this stuff. You want to do exactly what you do for Data Merge: prepare a file with field-value replacements, do your QC and proofreading on the contents of that file, then process the boilerplate base document with the replacements file. EXACTLY my docs are policy manuals, SOPs, processes etc. so i have to cite statutes, regulations, regulatory agencies, countries, states/provinces, etc over and over and over. Quote Link to comment Share on other sites More sharing options...
larrystuartjr Posted February 20, 2021 Author Share Posted February 20, 2021 2 hours ago, MickRose said: @larrystuartjrI'm pretty sure this can be done. I've attached a spreadsheet file and an afpub file. The afPub file contains a screenshot of the Data Merge Manager dialogue box settings used. The spreadsheet links into the pub file and any one row is selectable and the new content will flow through the document. Although text variables aren't directly supported, this way of doing it seems to be a good workaround. I think you have to be a bit careful with spreadsheet column headings - short & simple is best. Let me know if this is what you want or not. untitled.afpub 1.61 MB · 1 download Book1.xlsx 6.79 kB · 2 downloads Thanks so much for this. I was thinking along the same lines as this is close. I will still have to go through and create a "template" to match all of the fields (so much for my Saturday LOL) but after that this document can be modified by the data source row creating the doc for a different client. Thanks for getting me over the hump on how to do it so I don't have to go back to adobe. Quote Link to comment Share on other sites More sharing options...
MickRose Posted February 20, 2021 Share Posted February 20, 2021 You're welcome. I'd recently asked if text variables could be used and your question made me dig a little deeper and come up with a usable workaround. I just wish Serif would produce a proper in-depth user guide. larrystuartjr and sfriedberg 2 Quote Windows 10 Pro, I5 3.3G PC 16G RAM Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.