Rick Jelliffe did a minor update to the current ISO Schematron implementations. Please download them here: http://www.schematron.com/implementation.html
Briefly the changes are:
- A fix for running EXSLT Schematron.
- New parameter “terminate” to stop validation on the first failed assert.
- A new version of the Schematron ANT task is also available.
Schematron
Just a quick note… On every PC there is a text editor already available. And there are also some more sophisticated text editors available for free like this one Notepad++ which offer XML syntax coloring and support for different encodings which is important for XML documents. So very often you just need to do a quick change to your XML file and then you also need to make sure the file is still valid afterwards or the XSL transformation still works as expected. Imagine you just need to remove some typos or wrongly written names in the content.
This is where XML ValidatorBuddy can help you to save the money for an XML editor with a lot of features you will never need or use. Edit your XML files with your favorite text editor and do the validation of your documents from the Windows File Explorer and ValidatorBuddy.
validation, ValidatorBuddy
Running any XSL transformation as easy as getting the file properties in the Windows File Explorer? A user friendly way to run XSL transformations allows a wider range of people to work with XML files. Therefore the next version of XML ValidatorBuddy will provide a command to do XSL transformations. So XML ValidatorBuddy makes it possible for everyone to run XSL transformations for any XML file using any XSL stylesheet by a simple dialog:

XSL transformation dialog
All you need to do is to install XML ValidatorBuddy (available with version 2.7) and the free AltovaXML parser.
ValidatorBuddy, XML, XSL
A tutorial is a wonderful thing. Learning how to write Schematron rules with a tutorial is also a wonderful thing. Unfortunately validating XML instance files against a Schematron schema is not always easy. But if it is cumbersome to work with Schematron schemas, then going through the tutorial is also no fun. XML ValidatorBuddy makes it easy to validate XML instance files against a Schematron rule set directly within XMLSpy. This enables you to focus on Schematron itself and not on how to use it.
I take the files from chapter 7 of the Schematron tutorial available at http://www.dpawson.co.uk/schematron/keys.html . Of course the method described here to create and validate the sample files can also applied on any other chapter of the tutorial.
The basic steps are:
- Select and copy the content of the Schematron schema and XML sample instance files directly from the web pages of the tutorial (with Ctrl+C).
- Create a new .sch document for the Schematron schema and a new .xml document for the sample XML in XMLSpy. Paste the file content with Ctrl+V.
- Save the files anywhere you like.
- Add a folder to the Project open in XMLSpy and put both into the new folder. ValidatorBuddy recognizes that there is a .sch file in the same project folder as the XML instance and takes this schema for Schematron validation.
- Make the .xml file the active document in XMLSpy.
- Press “Validate” on the Schematron tab of the XML ValidatorBuddy plugin window.
- Check the results
After doing this the Schematron tab shows the following result:

Schematron tutorial chapter 7 result
Schematron, ValidatorBuddy, xmlspy
Here is a summary of the changes in XML ValidatorBuddy 2.6:
Copy validation report in XMLSpy as XML
In the past it was not possible to access the validation report in the XMLSpy plugin for further processing beside scrolling through the error list and selecting the error location. Now the Schematron and Xerces tab are providing a button to copy the validation results as a new XML document in XMLSpy. The XML has the same structure as the log file generated by a batch validation.
Validate instance files with selected Schema
Validation from the Windows File Explorer supports a new command to validate one or multiple XML instance files against a selected schema file. This command overwrites any present xsi:SchemaLocation or xsi:NoNamespaceSchemaLocation. If no schema location attribute is in the XML root element the schema is loaded as NoNamespaceSchemaLocation. This functionality uses the Xerces SAX validator and is therefore also handy on validating huge files without any schema already assigned.
Creation of batch log in UTF-8
The batch log file is now written in UTF-8 encoding. The UTF-16 format without a BOM which was used in the past caused some problems on reading. Several people requested to change this to UTF-8. Of course this is the better choice anyways.
ValidatorBuddy, Xerces-C, xmlspy
The new menu of the TortoiseXML functionality (accessible from the Windows File Explorer) of XML
ValidatorBuddy will look like this:

New menu in ValidatorBuddy
It is a new approach to set the focus on the tasks people want to do with XML and not on having support for various XML parsers.
- Putting the Xerces parser to the front together with a statement about large file support provided by the SAX interface.
- Other validation engines (AltovaXML, XSV) are now accessible through the “Other..” menu.
- A brand new command “Validate against Schema…” which allows to validate also XML instance files without any schema already assigned. This command also allows to override any SchemaLocation and NoNamespaceSchemaLocation attributes present in the XML.
XML
ValidatorBuddy 2.6 will be available within the next couple of days.
TortoiseXML, validation, ValidatorBuddy, XML
Today I read by chance a post in the oXygen XML editor forum (here) if it is possible to get the XSL which is used in the last step of Schematron validation to validate the XML instance. To make it short: in oXygen there is no special functionality for it, with ValidatorBuddy in XMLSpy you get it with one click.
Some background: Usually, to validate a XML instance document using Schematron a XSL stylesheet which is generated from the Schematron schema is applied to the input XML. To generate the XSL to validate the XML another XSL stylesheet that implements the Schematron definition is used. In addition you also need to do some pre-processing to resolve the includes at least. Guess what, this is also done with the help of a stylesheet.
To simplify this for the user and to save time XML ValidatorBuddy has a button to get the final XSL used to validate the XML with one click:

Get XSLT button for Schematron
On the upper-right corner you can see the “Get XSLT” button. If a Schematron stylesheet is assigned to the XML a new .xsl document will be created in XMLSpy with the stylesheet to validate any instance document.
You can then save this stylesheet and apply it to any XML with simple XSL transformation or you can use it to debug the Schematron schema in the built-in debugger of XMLSpy.
Schematron, ValidatorBuddy, xmlspy, XSL
Internet Explorer is really strange. Yesterday I noticed that the empty cells in the “General” column of the generated HTML from the validation log coming from XML ValidatorBuddy were not shown. I mean no borders are around them but the <td> elements are present.
So I took a look at the CSS styles of the HTML and set the empty-cells style to “show”. No difference. IE still didn’t show the empty cells. I thought to myself: “There is a style named “empty-cells” and you can set it to “show” but even then empty cells are not shown, well …”
As usual the next step is to search the Internet. Looking for “empty-cells show” gives a lot of hits complaining that this is not working in IE. Ok, at least I’m not alone with the problem. Luckily there are also some hints how to solve it. I choose the “border-collapse: collapse” approach. How stupid I am that I didn’t know right from the start that collapsing the borders is the way to show empty cells. I mean there is nothing more obvious…
Anyways, the output of the sample XSL transformation of the ValidatorBuddy batch validation log looks much better now:

Validation report HTML with borders
Batch validation, HTML, InternetExplorer, ValidatorBuddy, XSL
Having the results of the XML batch validation as a log document in XML format is nice but giving the option to automatically run a XSL transformation on the log is even nicer. Therefore I added to the upcoming release 2.5 of XML ValidatorBuddy a task which runs any stylesheet after the batch has finished to produce any other possible text output from the log file.
The batch dialog of ValidatorBuddy got the new “Transform output file” option in the Output file settings group:

Output file settings
On clicking the “Configure…” button a dialog appears where you can select the XSL stylesheet and the name of the output file to generate:

Configure output transformation
In this case ValidatorBuddy will execute the batch and take the valbuddy_log.xslt afterwards to transform the output log to the AltovaExamples.html file. Please note that you need to have the free AltovaXML parser installed in order to successfully run this transformation.
Of course you can specify any XSL here to create the output you need but the installer of ValidatorBuddy will put the sample valbuddy_log.xslt I created into the installation folder. This way you can get HTML from your log without any extra effort on your side.
To create the XSL I used the quite impressive Altova Stylevision tool. I have to admit that I’m not really an expert in writing XSL stylesheets and it would take me hours just to have this rather simple XSL working. But there is no need to be an expert in XSL when you use Stylevision. Just design the layout and select the output type you want to create from your input XML. In my case I just did a few drag-and-drop operations, added two XPath based conditions to have a green background if a file is valid and a red if the file is invalid. Then I told Stylevision to produce the XSL for me an save it. Voilà! It took me about 20 minutes and that without being a stylesheets guru.

Validation log transformed to HTML
All of this is available in XML ValidatorBuddy 2.5 coming soon…
batch, HTML, ValidatorBuddy, XSL
As promised I write a few lines about the Schema documentation generation functionality for folders. This means that for all W3C schemas (files with .xsd file extensions) in a folder and its sub-folders a HTML documentation is created using the XS3P stylesheet.
It simply works this way: You select a folder in Windows File Explorer and open the context menu with a right-button click. Then you select the “Generate Schema documentation” command from the TortoiseXML menu. The command will notice that only a single folder is selected and offers now a dialog where you can choose if you want to write the generated documentation HTML next to each schema found or in a separate folder. The advantage of the separate folder is that all generated documentation files are afterwards at one place. You could easily add them to a ZIP archive and send them by email for example. The advantage of saving the files next to the schema is that you have the documentation at the same place as the schema. Maybe easier if you like to keep the documentation for later reference.
During the generation the hourglass mouse cursor is shown and after the process has finished a message box is displayed to tell you that all schemas are now documented. As usually just double-click the single HTML files to open them. Quite simple if you want to provide W3C schema documentation, isn’t it?
ValidatorBuddy, W3C, xs3p, ZIP