Where have all my data elements gone?

by Peter on October 3, 2009

in XpressDox Cookbook

Post image for Where have all my data elements gone?

Sometimes you will have marked up a template and then when you run it, one or more of the data elements don’t appear in the data capture interview. Conversely, sometimes the data element may appear in the capture interview but not on the merged document.

It’s in the data capture interview but not in the merged document

XpressDox has a number of commands which are used to choose data elements, either from lists or data sources or whatever. These are the commands listed in the “Data Capture” category of the Command Editor .

These commands are very literal in their behaviour. In other words, they permit the user to choose or capture a value for a data element, but they do not cause the data to appear in the merged document.

For example, <<ChooseFromList(Province, ...)>> will present the user with a drop-down list of options from which to choose the value of the data element named “Province”. It does NOT cause the value of the data element to be inserted into the document. There needs to be a fillpoint such as <<Province>> (or maybe <<ToUpper(Province)>>, or something) which tells XpressDox where (and how) to insert the data element value.

A very simple example of why you might want the user to choose a value and yet not have that value in the merged document is the situation where you would use the choice in one or more If or When commands to include or exclude paragraphs or text from the end result. Or, perhaps, you want the option to be captured when one template is run so that it can be saved and used when running a subsequent template.

It’s in the Template but not in the data capture interview

You have authored a template with some good conditional assembly in it, but the XpressDox data capture interface does not present some of the data elements for capture.

An example might be:

I appoint <<Fullnames>>, and if <<When(GenderOfAppointee = “F”,she,he)>> is unavailable, then <<When(GenderOfAppointee = “F”,her,his)>> cousin.

Because the data element GenderOfAppointee only appears in the When conditional expression, XpressDox needs an explicit request to capture this data item. This can be done via a Choose... command (e.g. <<ChooseFromRDBList(GenderOfAppointee,F,M)>>), or by using the command <<CaptureDataElement(GenderOfAppointee)>>.

The Reference article Using CaptureDataElement during data capture gives some background to this issue.

It’s in the interview but I don’t know what it’s name is!

This will be the case with ChooseFromDataSource and similar commands, and also where you have used <<Caption()>>. This is discussed in Determining what a data element name is.

Related posts

Leave a Comment

Please remember your comments are subject to our comment rules.