COSIMA Scripting: Achieve more with fewer clicks – from Excel to XML

COSIMA Scripting: Achieve more with fewer clicks – from Excel to XML

Welcome to our new “COSIMA Scripting” blog series! With the help of scripting, COSIMA users with basic programming experience can create new and very specific functionalities on their own. We will be presenting various examples from our customers to show the exciting possibilities that are out there.

Importing large amounts of data in DOCUFY COSIMA

We begin our scripting series with a typical use case that our customers often inquire about: Certain data is outside DOCUFY COSIMA, but is needed as part of the documentation in the content management system. Since the data can be structured in any way, there is no standard solution that addresses the issue for everybody.

Scripting provides a relatively quick and easy way to transfer content to COSIMA. The following example demonstrates this using an Excel document.

As part of the documentation process, one of our customers needs to add a large number of further references to the documentation. For this purpose, the customer has several Excel documents structured as follows:

The solution: COSIMA Scripting

One option would be to transfer all of the content to DOCUFY COSIMA using copy and paste. However, this is a lengthy and, above all, error-prone process when there are large amounts of data. In the example, our customer’s file contains over 3,000 entries alone, meaning the manual approach is no longer feasible.

Possible structure of an Excel list

The new smart copy and paste feature (available in versions from COSIMA go! 8.5) simplifies the process somewhat by creating a valid structure with elements. Yet this method also requires some manual rework, which can be very time-consuming when there are large amounts of data.

This is why we created a script that reads out the information from the Excel document and imports it directly into the desired structure. This creates a list in DOCUFY COSIMA which contains the index entries (“keyword” column) and URL links (“link” column). A new context menu entry in the XMAX editor allows this action to be executed.

The COSIMA script described here is an enormous help for our customer, since they regularly have to import Excel documents and the manual approach is very time-consuming.

Philipp Schulze, Head of Project Development, DOCUFY GmbH

An update mechanism is not provided, which is not necessary for our customer in this use case.

Whether it makes sense to automate process steps always depends on the individual case. Important criteria to consider include how often the action needs to be executed (daily, weekly, monthly, etc.) and how long it takes to execute the actions manually (5 minutes, 1 hour, 1 working day, etc.). As the example with over 3,000 entries demonstrates, the amount of time required is particularly dependent on the volume of data.

Your feedback is very welcome

With articles covering use cases from Excel to XML, our new blog series will be taking a closer look at the powerful functions within COSIMA Scripting. The upcoming articles aim to provide readers with the inspiration to recognise where their own processes can be improved. We are always happy to receive examples and suggestions from you to be included in future articles in this series. Upon request, our customers can receive the COSIMA scripts featured in the articles with a short guide free of charge. If you are interested, simply send a quick email titled “COSIMA Scripting 01: From Excel to XML” to You must have version 8.0 of COSIMA or higher in order to use the script.

For further support or help getting started, we hold regular group training sessions as well as one-on-one workshops. We also provide scripting support as a service, if you require direct assistance from our developers with scripts you have created yourself.

Once again, we are always happy to receive feedback and suggestions for further use cases. You can write down your thoughts in the comments or send an email to



Philipp Schulze