jump to navigation

XMLP and Checkboxes in PDFs January 2, 2008

Posted by Duncan in Oracle, PeopleSoft, PeopleTools, XML Publisher.

I’ve been having problems getting checkboxes to print correctly when creating PDFs using XMLP. I was faced with tiny little diamonds like those on the left here, when I was expecting ‘standard’ checkboxes like those on the right:


It turns out that the XML Publisher default PDF output font does not include a glyph to represent a checkbox and this is an issue faced by one or two Oracle people already (Tim Dexter has written about it here). I thought I add a quick write-up as I’m tackling the issue from a PeopleSoft perspective.


Firstly, a quick recap for those who haven’t used checkboxes before in XMLP. You output your XML in the usual fashion and for your checkbox have the process spit out a single field (in most cases I’d guess this would be a ‘Y’ or ‘N’ value, but I’ve used it a couple of times where you have 5 or 6 checkboxes depending upon a single value). Then, from within Word, open the Form toolbar and insert as many checkboxes as you need. Go into the properties of your checkbox, press the ‘Add Help Text’ button and choose ‘Type your own’. In the freetext field enter:


replacing the ‘fld_YES_NO1’ with the name of the XML element/field you’re basing it’s state on and the Y with the value you wish the box to be checked for.

Now if you print this, there’s a good chance you’ll get the small diamonds I had instead of the ‘standard’ checkboxes we’re all used to.

So, how to fix it?

First, have a look through the symbols found under “insert symbol” in Word and choose the checked and unchecked symbols that you want to use. Make a note of the font and character code. Wingdings 168, 253 and 254, plus Wingdings2 81-84 and 163 are a good place to start.

What I couldn’t get to work

The documentation seems to suggest that you can update xdo.cfg to specify the settings for all domains and XMLP reports. Using Notepad, create an xdo.cfg file. You can find a full description of the contents in Chapter 10 of the user guide but the file I used was thus (with the bits you’ll need to change in red):

<config version="1.0.0" xmlns="http://xmlns.oracle.com/oxp/config/"&gt;
      <property name="rtf-checkbox-glyph">Wingdings2;84;163</property>
      <font family="Wingdings2" style="normal" weight="normal">
         <truetype path="c:\windows\fonts\wingdng2.ttf"/>

The first red section contains the font name, the checked character code and the unchecked character code. Place this file under:
C:\Program Files\Oracle\XML Publisher Desktop\Template Builder for Word\config\ (or wherever you installed XMLP)

Now go and preview your document from within Word. If you’ve got the above correct you should see your desired checkboxes.

Testing in the PIA

If you have a data source and report definition set up already, you can upload your template and place the xdo.cfg file in the <ps_home>\appserv directory. You don’t need to reboot the App Servers when you update this file. You can then use the preview from within Report Definition > Template tab to view the results. Your checkboxes should also be correct at this point, if not, check your template and xdo.cfg file.

Now, how do we get these on the Process Scheduler?

The documentation suggests that it’ll just work from here without changes to the contents or location of the xdo.cfg file. Unfortunately running the report within the Process Scheduler still returned the wrong checkboxes.


The workaround that I used was to specify the desired settings on a per document basis.

Go into the template document properties within Word and then the custom tab. Enter the following two settings:

Name: xdo-font.<fontname>.normal.normal
Type: Text
Value: truetype.<path to font file>
Example: truetype./appl/psoft/pshcm/WINGDNG2.TTF

Name: rtf-checkbox-glyph
Type: Text
Value: <font_name>;<checked symbol>;<unchecked symbol>
Example: Wingdings 2;84;163

The font name can be anything you like, it doesn’t have to be the name of the actual font you are using. Just make sure that the fontnames in the two properties match.

This worked in both the preview from the XMLP Report Definition and via the Process Scheduler. The only downsides are you’d have to apply these properties to each report that you need to use checkboxes in, and if you need to move your fonts then you’ll have to update every report that contains it.

Useful Documentation

The XMLP for PeopleSoft PeopleBook (in PDF format) and the Oracle XML Publisher Core Components Guide can be found here.

Find the Tools library that matches the version you’re using, and drill into that to find the individual guides.

%d bloggers like this: