Using Tokens in OpenClinica CRFs and URLs

An important new feature in OpenClinica 3.3 is the ability to incorporate variables in your CRF display. When designing your CRF, you can embed tokens into your form design with some simple markup (such as ${studySubject} to print the Study Subject ID). When the CRF is rendered for a patient visit, the tokens are parsed and replaced with the appropriate values. So, if you now want to display the name of the study, visit name or number, or study subject ID on a particular place on the form, you merely need to insert the token in the right place. You can even display the value of an item – for instance if you want to display a value entered in section 1 on a later section of the form, just use ${item[‘item_name’]}, replacing item_name with the name of your item. (screenshot right-justified – overlay snippet of CRF w/token on top of snippet of LI text with parsed variable)

ParameterizedLink2

This feature can be used in much more powerful ways too, especially when combined with the existing ability to include HTML markup and javascript code in your CRF.

In addition, tokens can be embedded as parameters in a link to an external system, such as an imaging or genomic data store. With the use of parameters specific to the study subject and event CRF, the link can take the user directly to the relevant record in the external system. With a little bit of clever javascript, the form could even embed the image or other media directly. You’ll have to set up appropriate security rules in the external system to allow this, and ensure the two systems share the same identifiers. (screenshot of embedded image)

The design, coding, and testing of this feature has been developed in collaboration with our fantastic partners at CTMM/TraIT in the Netherlands. With them, we have been able to build a feature that will fulfill a key need of theirs (link directly to a patient image at point of data entry). With the feedback of others in the community we’ve been able to make it generalizable for a far broader set of capabilities, adding to OpenClinica’s powerful existing API and extensibility while keeping it simple and familiar.

Read more here.

Leave a Reply