0

Here is a task: I have excel file with table (for example columns are Name, Number and Address) and dimloma template. How can I automate filling my template and save all done diplomas to different files? Which way is the best to do this?

I currently working in Corel Draw. Corel Draw have Print Merge, but it's working with printing on paper, but I need saved files on my desktop. Is it possible in Corel Draw?

  • Hi! Welcome to gd.se. This is a question that's really asking for tech support on the product, and would be better asked on a Corel user forum. See the FAQ for guidance: graphicdesign.stackexchange.com/help/dont-ask – Alan Gilbertson Jun 4 '14 at 6:57
  • You could change the question to describe the problem (automate insertion of details) and ask about the best method to do that -- but don't mention Corel Draw, as that might not be best. I've done something similar using a VBA macro in Microsoft Publisher, for example, so the operation is definitely possible. But if you constrain yourself to Corel Draw then it's a technical support question. [Of course, the community may decide that even the changed question is off-topic, but I think it would stand a better chance of survival.] – Andrew Leach Jun 4 '14 at 7:02
  • 1
    Have you considered simply printing to PDF? – KMSTR Jun 4 '14 at 7:10
1

The easiest solution would probably be to install a PDF printer (such as PDFCreator: http://sourceforge.net/projects/pdfcreator/) and use the Print Merge feature to print to a PDF file, then use an application such as jPDFTweak (http://jpdftweak.sourceforge.net/) or pdftk (http://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/) to burst the document into single pages if you need separate files for each diploma.

However, in the past I did this in a different way:

You can save the diploma template as SVG, which is just a text file, and use placeholder strings instead of names. Then, using a script that reads the list of names from a CSV (a text file format which you can save from Excel), you can use text search and replace functions to replace the placeholder strings in the SVG file with actual names. Finally you can use e.g. Inkscape from the command line to convert all the files to a different format.

Note that if you don't know any scripting language, the PDF printer solution will be easier for you; this answer is mainly intended for other people who might be using software without a dedicated Print Merge feature.

Here is an example Python script to generate the SVG files with replaced names. It expects an SVG diploma template called "template.svg" that contains text objects with the text FIRSTNAME and LASTNAME as placeholders, and a CSV file called "recipients.csv" with column names "FirstName" and "LastName" and fields separated by commas.

#!/usr/bin/python
# coding: utf-8

import csv

template_f = open('template.svg', 'r')
template = template_f.read()
template_f.close()

recipients = csv.DictReader(open('recipients.csv', 'rb'), delimiter=',', quotechar='"')
t = template[:]
nfiles = 0

def write_file(content, num):
    output = open('diploma_%02d.svg' % num, 'w')
    output.write(content)
    output.close()

for recipient in recipients:
    firstname = recipient['FirstName'].strip()
    lastname = recipient['LastName'].strip()
    t = t.replace('FIRSTNAME', firstname).replace('LASTNAME', lastname)

    write_file(t, nfiles)
    t = template[:]
    nfiles += 1
1

As mentioned by Krzysztof, the simplest/quickest solution is to:

  1. use the Print merge function (if you're not clear on how to do that, leave a comment, and I can explain in more detail)

  2. print the resulting file to a PDF file using a PDF printer or CorelDRAW's native Publish to PDF function

  3. use something like PDFill PDF Tools to either split the PDF up into multiple one-page PDF files, or convert all of the pages to images.

I've done this in the past e.g. for generating 200+ namebadges, and it works beautifully.

0

It can be done by corel macro/vba. Like on these :

http://www.youtube.com/watch?v=s-wMp4xjv9A and http://www.youtube.com/watch?v=gRI-ef-xHlU

The variable data is from excel.

Macro will replace/retype the text with data from specific column of excel, refer to record number.

Then export it (both design and data/filling text) as high res bitmap, or publish it as PDF.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.