Python scripting for PDF reports

NLS Translation

Previous  Chapter  Next

Preliminary note


For translating the report Items there are translation files for each provided language (English, French, Chinese, Japanese and German).

The text items of the report are translated by NLS files (*.lng)

These are plain text files and can be edited with regular text editors, like Notepad++.

 

Just define the internal name of the desired item and add the desired translation after the equal sign (beware that the item name is not already existing)

 

PDF_NLSDesc

 

To get the desired item in the Python script, use the getNLS(…) method from the NLS-Class

The parameters are: the (exact) name of the item and (optional) a default string, for when the item cannot be found.

 

PDF_NLSGetNLS



By default the language files are located in the installation path …\Lib\site-packages\cenpylib\languages.

 

PDF_LanguageDefltLocation

In case of customization, the complete languages folder can be copied to a desired path, which is given with the create command. Otherwise the report takes the default files.

 

PDF_LanguageCustLocation

 

Customer related settings and translation can be done there. Only the desired language file needs to be edited.

Following listed settings are supported to adjust the report. If the item doesn't exist, the defaults form the script will be taken



Report items


Below the list of available report items is shown.


PDF_ReportItems

 

PDF_NLSItems PDF_NLSItemsCN

 


Information

Note : if there are two hashes ## in the costs item, they will replaced by the currency Sign, e.g. Costs [€]


 


Previous
Previous page
Chapter
Chapter page
Next
Next page