Copy link to clipboard
Copied
Hi evertyone
I am looking for guidance of a issue I am trying to improve
Everyday I run receipts, there are 30 odd 1 page receipts that are set up in individual word documents, on a normal day we are required to print anywhere between 100 and 3000 receipts. Currently we need to open up every receipt individually to print them through mail merge each connecting to a seperate .csv file. I want to improve this process.
Is there a way to set up an InDesign document where I can include all 30 receipts in one document, (maybe using msater pages), and then using mail merge connecting to one .csv file which contains a field that defines which recept that person should get
e.g. the file would have
Field 1 Field 2 Field 3
Name Address Receipt
Ms Sample 1 Sample St Xmas20
Mr Sample 2 Sample St Tax20
Therefore record one would receive receipt Xmas20 etc etc and I could print all in one go
Appreciate any help on this, if you would like more infromaiton please let me know
Have a great day
Copy link to clipboard
Copied
Hello tobyb71827903,
Currently we need to open up every receipt individually to print them through mail merge each connecting to a seperate .csv file.
Can you expand on this a little more?
So you open each word document? and what copy and paste into a csv? or is the csv what is generated? if this is the case is the csv 1 per receipt?
Copy link to clipboard
Copied
Hi
Yes, of course, when we come to receipting we run an export from our database. So at the end of our day when the work is finished we export receipts which generates 30 separate .csv files, one relating to each receipt. These .csv files only include those people who require that receipt. So if on that day only one person’s requires receipt Xmas20 that .csv file will only contain that one record. This also prints a count of how many people should get each receipt for cross checking purposes. We then have to open up each word document one at a time, go through the regular steps that words prompts you for, before printing the documents.
Understandably this takes a fair amount of time with 30 different documents and word is prone to loosing connections.
Every month or two we have a new receipt so what is now 30 receipts will be say 40 by the end of the year and so on. We have the same issue across half a dozen projects so you can imagine the time that is spent each day printing the files.
In a perfect solution I would like to be able to just export one .csv file containing all records and using a flag print the appropriate receipt, that is contained in one document/file
Hope this clears things up
Copy link to clipboard
Copied
So just to clear this up. You can't export one csv? but infact have to export them all individually? Which is why this current process is so painful?
So if could could combine the CSVs in an automated process this would save you a lot of time? Or if indesign could combine all the CSVs in one document that would also save you a lot of time?
Copy link to clipboard
Copied
We certainly can export 1 .csv, thats easy. We only export them individually at the moment as the receipts are all seperate files
The part that takes the time is having seperate word documents, this is the aspect I want to improve and I thought InDesign may have that ability to have all receipts in one file
Copy link to clipboard
Copied
Oh i think i get it now.
You want to have based on your mock fields up top a different receipt output base on that field
ie
Field 1Field 2 Field 3
Name Address Receipt
Ms Sample 1 Sample St Xmas20
Mr Sample 2 Sample St Tax20
Copy link to clipboard
Copied
Yes, thats it
Copy link to clipboard
Copied
This is doable with a script. Doing a quick search I can't find any that does this out of the box and coding one from scratch would take a bit of time.
What I do reocmmend is having a look at https://meadowsps.com/designmerge-pro/ Ive recommended this to a client before any they were pretty happy with the results. Send them a quick email and ask for a trial or a demo if you are interested.
If you're not instrested in this then I would recommend staring a new post asking for help or scripts that can use master pages or have modified content based on differnt content in fields. Someone will have spent the time creating something that they might share.
Copy link to clipboard
Copied
Thanks for taking the time to respond
I might take your advise re scripts
I feel like this should be achievable without too much difficulty, so with stick with finding a solution first
Copy link to clipboard
Copied
Hi @tobyb71827903
I'm not sure I understand your problem correctly... what exactly isn't working for you with the InDesign data merge function?
At the end of the day create a merged document, where you can place multiple instances on one page (see "Merge records" in the user guide).
Copy link to clipboard
Copied
Hi Jens Trost
The InDesign merge is working, I have an understanding of how this works. However, I want to see if the merge can do more advanced work
To be honest I am not sure how to clarify the issue more than I have already
As you can see in the image below I have two master templates set up, I then want to connect to the data via data merge and using Column C below, I want to print the documents where if receipt = 'Xmas20' use master 'Xmas-master' and if receipt = "Tax20" use master 'Tax-master' as the content
Copy link to clipboard
Copied
Hide the document master information on a hidden layer on the page, with a text frame called "master-info". I assume these are all single-page entries for the merge.
After executing the merge, the general idea for a script is:
var pages = app.documents[0].pages;
for (var i = 0; i < pages.length; i++) {
pages[i].appliedMaster = app.documents[0].masterSpreads.itemByName(pages[i].textFrames.itemByName("master-info").contents);
}
Copy link to clipboard
Copied
Hi brianp311
Thanks for taking the time to respond
Yes they are all single page entries, I will look into what you have suggested, to add something like
If <<Receipt>> is "Xmas20" then Xmas (refering to ethe hidden layer)
thanks
Copy link to clipboard
Copied
pages[i].appliedMaster = app.documents[0].masterSpreads.itemByName(pages[i].textFrames.itemByName("master-info").contents);
@tobyb71827903If you look at the code provide want you are wanting is sort of technically done.
pages[i].textFrames.itemByName("master-info").contents
Having a text box named (this can be done through layers) master-info and putting in that field <<Receipt>>. Then having the masterpages the same name as the Receipt fields should swap.
Copy link to clipboard
Copied
Thanks
As you can tell I am a novice in this area. I will read up over the weekend to understand this more, and get it working, thanks
Copy link to clipboard
Copied
Its ok, I had to look at it a few times to work out what he had coded. It's actually quite a good approach.
Copy link to clipboard
Copied
If the master page is named something differently than what is in the cell, you can do an if check:
if (...contents == "Xmas20") {
... appliedMaster = ...("B-Xmas-Master");
}
Sorry, on mobile.