Skip to Content
Feb 22, 2011 at 12:24 PM

Running NetWeaver's XSLT processor from Oxygen



I am using Oxgen XML Editor (version 12.1, build 2011012011) to create my XSLT mappings. Having tested these mappings successfully offline they are imported onto our SAP-PI ( SAP NetWeaver 7.01 ). However, sometimes mappings that work in Oxygen fail on SAP-PI. Therefore, I would like to use NetWeaver's XSLT processor as Custom Engine within Oxgen.

Triggered by the blog of Thorsten Nordholm Søbirk

Running NetWeaver's XSLT processor from XMLSpy

I copied the archive sapxmltoolkit.jar into the lib directory of the Oxygen installation path. Next I went to menu Options -> Preferences -> XML -> XSLT/FO/XQuery -> Custom Engines and defined the following settings:

Working Directory = .
Command Line = C:Program FilesJavajdk1.6.0_07 injava -cp
 "C:Program FilesOxygen XML Editor 12libsapxmltoolkit.jar";
-xml="C:	empz_tempinput.xml" 
-xsl="C:	empz_tempstylesheet.xsl" 
-out="C:	empz_tempoutput.xml"

In addition, within the Transformation Options I set:

For the sake of simplicity I used a plain stylesheet without any Java extensions. When I delete file "output.xml" in "C: empz_temp" and execute the transformation the file is recreated. Thus, I am sure that the NetWeaver XSLT processor has been used.

However, instead of hard-coding filenames and pathes I would like to use the built-in variables of Oxygen like "$" etc. Most of the XSLT mappings use a Java extension which is located in the same directory as sapxmltoolkit.jar (C:Program FilesOxygen XML Editor 12lib).

There are 2 major problems that I am facing now:

(1) How must the Command Line look like so that I can use Oxygen's built-in variables as input for -xml, -xsl and -out? (2) How must the Command Line look like so that the Java extension archive is recognized?

Your help and valuable input is very much appreciated.