Altova StyleVision Server 2024

Syntax and description

The generate command (short form gen) generates one or more output files (HTML, PDF, RTF, and/or DOCX) by transforming the input XML file using the XSLT document/s contained in the input PXF file.


stylevisionserver generate | gen --inputxml=Filename [additional options] InputPXF


The --inputxml option is mandatory; it gives the path to the XML file.

The InputPXF argument specifies the path to the PXF file which contains the XSLT document/s that will be used to generate the output document/s. PXF files are created with Altova's StyleVision application.

Each output format is generated by specifying an option for that output (see Options list below). The value of each option is a path that specifies where the output is to be generated.


Note:StyleVision Server uses Apache FOP, the FO processor of the Apache Project, to generate PDF files from FO. Apache FOP is installed with StyleVision Server at the following location: On Windows systems, ProgramData\Altova\SharedBetweenVersions; on Linux and macOS systems, in a descendant folder of the StyleVisionServer2024 folder. Note that Apache FOP requires that Java Runtime Environment 1.8 or later be installed on the StyleVision Server machine. For 32-bit StyleVision Server, install the 32-bit Java; for 64-bit StyleVision Server, install the 64-bit Java. For more information about setting up FOP, see the topic FOP Requirements.





Examples of the generate command:


stylevisionserver generate --inputxml=C:\MyFiles\ExpReport.xml --html=Test.html ExpReport.pxf

stylevisionserver generate --inputxml=C:\ExpReport.pxf|zip\ExpReport.xml --html=Test.html ExpReport.pxf

stylevisionserver generate --inputxml=altova://packagedfile/ExpReport.xml --html=Test.html ExpReport.pxf

stylevisionserver generate --inputxml=ExternalXML.xml --html=Test.html Test.pxf


The commands above contain the mandatory --inputxml option, the InputPXF argument (Test.pxf), and a minimum of one output-creation option (--html in all the examples above).

The input XML file to use can be located inside the PXF file (see second and third examples above) or it can be an external XML file (located outside the PXF file; see first and fourth examples above).

The --inputxml switch is ignored if the main schema source is DB or DB-XML, but it must be present for syntactical reasons, and you should use something like --inputxml=database.

If the output-creation option --html takes a relative path, as in the examples above, then the output file's location will be relative to the folder in which the PXF file is.





Use the --h, --help  option to display information about the command.


Options are listed in short form (if available) and long form. You can use one or two dashes for both short and long forms. An option may or may not take a value. If it takes a value, it is written like this: --option=value. Values can be specified without quotes except in two cases: (i) when the value string contains spaces, or (ii) when explicitly stated in the description of the option that quotes are required. If an option takes a Boolean value and no value is specified, then the option's default value is TRUE. Use the --h, --help option to display information about the command.



If you are using the Altova catalog mechanism, you can find the relevant catalog files in the etc folder of the StyleVision Server application folder. For detailed information, see the Catalogs section of the Altova StyleVision manual.


You can create CustomCatalog.xml from the template file CustomCatalog_template.xml. Make sure that you rename the template file to CustomCatalog.xml since this latter file will be the file that is used in the catalog mechanism (not the template file).


Note the following:


During a new installation of the same major version (same or different minor versions), the template file will be replaced by a new template file, but CustomCatalog.xml will be left untouched.

However, if you are installing a new major version over a previous major version, then the previous major version folder will be deleted—together with its CustomCatalog.xml. So, if you want to continue using CustomCatalog.xml, make sure that you save CustomCatalog.xml from the previous major version folder to a safe place. After the new major version has been installed, you can copy the CustomCatalog.xml that you saved to the etc folder of the new major version and edit it there as required.


© 2018-2024 Altova GmbH