# Form creation from OpenEHR Templates **Category:** [Tools](https://discourse.openehr.org/c/tool-dev/36) **Created:** 2020-06-13 10:18 UTC **Views:** 3178 **Replies:** 9 **URL:** https://discourse.openehr.org/t/form-creation-from-openehr-templates/780 --- ## Post #1 by @Mateen_Rajput Hi, I am wondering if there is a tool to create PDF forms from OpenEHR Templates. I used Ocean Template Designer to create OFD form and got it compiled and running (attached) but export somehow doesn't work. I tried exporting in VB code as well as in C#. In addition, I also tried with XML but couldn't figure out a way to create a full featured PDF form which can be shown to clinicians before further steps. I also had a quick look at Better Studio and LinkEHR but couldn't find any option. I encountered some errors while running ADL workbench so don't know if there is an option in it. I am wondering if there are tools which provide this feature. Best regards, Mateen ![Filled_Form|351x500](upload://sY2uTR46kFgcDKcUuTAjkLrzc9z.jpeg) --- ## Post #2 by @birger.haarbrandt Hi Mateen, my understanding is that you want to automatically create a PDF form from a template. I think that's a pretty cool idea. Unfortunately, I'm quite sure that there is no tool that can do this at the moment. The mentioned OFM format is Ocean specific and I guess will be of limited use for you. Better's Web Template Format or the OPT are the best starting point from my point of view. We have a tool inside our openEHR SDK that automatically creates java classes from OPTs (https://github.com/ehrbase/openEHR_SDK). Next week, my colleague will work on java docs and make the code more understandable. Combined with something like Apache PDFBox, I think it should be possible to implement such a tool. However, it might take some digging and developing on your side :grimacing: Hope this helps a bit, Birger --- ## Post #3 by @yampeku LinkEHR can generate LForms from archetypes /templates. Alternativelly, an html+js can also be generated. --- ## Post #4 by @erik.sundvall You'll find video demos of form building based on openEHR templates in several of the pre-procurement videos listed at: https://discourse.openehr.org/t/swedish-openehr-platform-procurement-q1-2020/247/9?u=erik.sundvall They are not PDF forms though. How will the PDFs be used? Will printed filled form responses be (semi)automatically scanned by some OMR software (like https://en.wikipedia.org/wiki/Optical_mark_recognition#Open_source_OMR_software ) or manually read and entered into some recieving openEHR system? --- ## Post #5 by @thomas.beale I've just moved this to (I think) the right place, which will help people find it more easily. --- ## Post #6 by @pablo Hi, the openEHR Toolkit has a pretty basic form generator from a template and we welcome any feedback to improve it, please check it out https://toolkit.cabolabs.com/ --- ## Post #7 by @Mateen_Rajput Hi All, Thanks for your comments. I know how to create Forms from Templates, the idea was to create "Portable Forms" from them to send it to clinicians before developing them and implementing them in a HIS. e.g. for cancers, the Forms are often dynamic and it would make more sense to have a prototype of a template as a PDF to send around and have doctors opinion about it. @yampeku: I tried it with some archetypes and got variable results i.e. some forms (html) were more neat than others. @erik.sundvall: No, I was talking about using them as a Prototype before implementing them. --- ## Post #8 by @erik.sundvall Regarding prototyping purposes, I think it would be very interesting to have/make an openEHR-template-based plugin to the Figma (https://www.figma.com/) prototyping tool. Figma seems to be a favourite of many of our Linköping University students, plus many in the UX world and academia. Starting from the JSON generated by "Export as Web template" in https://tools.openehr.org/designer (see image below) would likely be one of the simpler ways. Possibly interesting links: - https://www.figma.com/developers - https://blog.prototypr.io/figma-plugin-tutorial-1-6-65fc2102506 - How iFrames can be combined with Figma-documents https://blog.prototypr.io/figma-plugin-tutorial-2-6-2efb7944aa2 ![image|690x372, 100%](upload://szAzHwkbwCEpbMJvsbDbRRDEaxF.png) --- ## Post #9 by @ian.mcnicoll Hi Mateen, THe international CKM has a Printable view which is close to what you would need.https://openehr.org/ckm/templates/1013.26.291/printable THe Cabolabs tool kit might help https://toolkit.cabolabs.com The problem with templates (and showing them to clinicians) is that they are not app prototypes, they are datasets, and as you have noticed they can seem a but untidy, and will often not match the app requirement correctly. I think we could do with some better template visualisations for this purpose but I suspect we might be better to go straight for form builder type prototypes, and 'hide' more of the necessary infrastructure. --- ## Post #10 by @zacrify Hi OpenEHR plugin for figma sound great. Is there any attempt for this idea yet? --- **Canonical:** https://discourse.openehr.org/t/form-creation-from-openehr-templates/780 **Original content:** https://discourse.openehr.org/t/form-creation-from-openehr-templates/780