SAP Knowledge Base Article - Public

3065340 - Error "Document cannot be generated; ADS rendering of SAP template failed" Raised While Previewing Document

Symptom

After clicking on 'Preview' for a document, the following error message is displayed:

"Document cannot be generated; ADS rendering of SAP template failed"

The error can also be displayed as below:

"Document cannot be generated; ADS rendering of SAP template failed SYSTEM Template name: XYZ" (where "XYZ" is the name of the form template)

Environment

  • SAP Business ByDesign
  • SAP Cloud for Customer

Reproducing the Issue

  1. Open any Document in the system, e.g. Sales Quote.
  2. Click Actions -> Preview.

A popup window appears displaying the error message.

Cause

There are multiple possible causes for the issue:

  1. The template contains an extension field which is defined with the data type that only supports text, however a binary object (for example, an image) was pasted in the field, causing the rendering error.
  2. The document contains an invalid character in one of the text fields. 
  3. The form template is using a component of type "checkbox" to display a field of type "indicator". When the XML with the document data is passed to the form, the values are sent as "TRUE" or "FALSE". These values cannot be interpreted by the checkbox component, as it expects an integer value.
  4. The error might be caused due to customizations of the form which make it invalid

Resolution

The respective resolution for each cause pointed above is the following:

  1. Check the document (and if possible, the XML file generated by the document) for any binary objects being passed to the form template, and ensure that it is not bound to a field of type "text".
  2. Check the object in the system (and if possible the XML file generated) for invalid characters. Generally these will be found in Notes, Internal Notes and Internal Comments of the object.
  3. Check the form template for components which are being bound to a field of type "indicator", and ensure that a correct component in the form is being used to properly handle the boolean values sent through the XML.
  4. Check for customization made in the form template which could be causing the error. There is also an option to revert to a previous consistent version of the template to more easily identify the issues.

See Also

 3233470 - "Document Cannot Be Generated" Error When Generating Document Output or Preview 

Keywords

Preview document, ADS rendering failed, ProcessingException, InvalidDataException, Parsing Error , KBA , ads rendering failed , AP-RC-OUT , Output Management , BC-DWB-REP-EXT , Extensibility , Problem

Product

SAP Business ByDesign all versions ; SAP Cloud for Customer add-ins all versions ; SAP Cloud for Customer core applications all versions