The data fields will appear in the text surrounded by double angle brackets.įor text, you can use all of InDesign’s character, paragraph, or frame attributes to format them, including paragraph, character, and object styles. You can either click an insertion point in your text frame (I highlighted my XX placeholders) and double-click the data-field name, or drag and drop the data-field name into place. Next, I moved the data-field names into the layout template. Go back into your text editor, or Microsoft Excel, to delete them as necessary. This can easily happen if you’re using Microsoft Word as a text editor, where tab characters aren’t always visible. Sometimes, you may get an error message, “The data source has one or more empty field names….” This indicates your data source may have extra columns which are empty those must be removed before Data Merge can use them. The palette should be populated with data-field names that match the column heads (top row) of the source file. I chose Select Data Source from the palette menu, and selected the data-source file we created in Part 1. When first opened, the palette shows the basic instructions for how to use it. To do this, I opened the Data Merge palette (Window > Automation > Data Merge). To create a frame for the pet image, I simply made a placeholder graphic frame with the Rectangle Frame tool. While creating the card I placed “XX” wherever the text data will be inserted. This card was created at its printed trim size, and contained the boilerplate information that doesn’t change (for example, the logo and the text of the card), and data-field placeholders. In Part 2, I’ll show how to create the target document?the InDesign document into which the data will flow?and how to link the data to the document, and preview the results.įirst, I’ll created the reminder card layout for our imaginary veterinary hospital. After describing what Data Merge can do, I described the data-source files it can use. Var cols = Math.min(, data.Last week I began a series on using InDesign’s powerful Data Merge feature. fill the destination table with contents of the 2D array While (paragraphs.length) data.push(paragraphs.shift().split('\t')) convert the contents of the 'xls' frame into a 2D array 'data' create a new text frame and put the contents of the xls file into it xls_file = xls_file.openDlg() // <- use it if you want the dialog window Var xls_file = new File( '/table.xls') (a first table from the first text frame of the first page) You can copy in Excel the list of paths to the INDD files run the script and get the PDF files and updated INDD files.īasically it can be something like this: var doc = app.activeDocument ViewPDF: ,Īpp.linkingPreferences.checkLinksAtOpen = false Īpp.pdfExportPreferences.viewPDF = false Īpp.linkingPreferences.checkLinksAtOpen = settings.checkLinksAtOpen Īpp.pdfExportPreferences.viewPDF = settings.viewPDF Var preset = ("") Īpp.activeDocument.exportFile(ExportFormat.PDF_TYPE, file, false, preset) ĬheckLinksAtOpen: , If (link.status = LinkStatus.LINK_OUT_OF_DATE) link.update() Here is the script that takes list of INDD files (full paths!) from the clipboard opens them, updates links, saves PDFs (in the same folders with the same names as opened documents), saves and closes the INDD files: var settings = save_setting()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |