Use 'XML Structure Section. Open Element' (CMS009) to define the XML elements. Use option 11='XML Structure. Open Section' in (CMS006) to open (CMS007). Use option 11='XML Structure. Open Section Elements' in (CMS007) to open (CMS009).
The elements are the lowest level in the XML structure and define the content to be included in the XML file. The content is either data from a field in an M3 Business Engine table, a calculated field, or a manually specified value.
The logic and functionality available in (CMS009) is highly dependent on the format selected in (CMS006).
Elements with type 1 (Text element) contain the data, while Elements with type 2 and 3 are used to create sub-sections (define start and end elements).
Used when text elements are the source of data specifying where the data should be retrieved from. The most used sources of data are 1-'Field', which is used when fetching data from tables or virtual fields.
Used as internal description in (CMS009), and never included in the XML file.
The element name to be used in the XML file, this can only be changed for XML structures with format 3 - Open. See below for standard used for format 1 and 2.
Labels are included in the XML file. Attribute 'Label' (defined on the F panel) holds labels translated to the correct language (based on user, customer, or supplier).
These methods are used to decide how the label should be set:
Indicates if Debit/Credit code information should be included in the XML file, and is only displayed for fields that have field information code equal to A01'-Currency' on 'Field Group. Display Permitted Field' (CRS109/E).
If field Debit/Credit code is selected as an attribute, 'D-C' is included in the XML file. If the M3 BE table has a separate field for D/C code that is used otherwise, the D/C code is set based on the amount and setting on 'Settings – General Ledger' (CRS750/E). The prerequisite for the attribute to be included in the XML file is that Debit/Credit code functionality is active for the division on (CRS750/E).
Only displayed for fields with data type 5-Decimal.
Numeric fields that are zero can be included in the XML file as 0,00 or as blank. If the field 'Hide zero value' is selected, then zero is included as blank, otherwise as 0,00.
The F panel is used to define the Attributes for the elements. A maximum of seven attributes per element can be defined.
Attributes 1 and 2 are reserved attributes and cannot be edited.
Element sequence number
Used as the sequence of the element within a section in the XML file. The sequence number is divided into groups:
|0001-3999||Reserved for predefined elements in the standard XML structures delivered (M3_STD_0x-0x). You cannot add or delete elements in this group|
|4001-6998||Reserved for predefined elements in the standard XML structures delivered (M3_STD_0x-0x) where the table is unique for country configuration component. You cannot add or delete elements in this group|
|7001-9998||Elements can be added, changed, or deleted|
If the source of data is set to 1-‘Field’ the element is set with these rules:
XML example with three elements
<UIIVNO Label="Invoice no">201401561</UIIVNO>
<VFORNO Label="CO no">1000025077</VFORNO>
For M3 standard report format, elements are structured in row and column format. Every column must belong to a row. In (CMS009), Start and end elements indicate a row, and all elements between those start and end elements belong to that row.
Used to sequence the element in the XML file and decide what row the element belongs to.
A range of sequence numbers is reserved for every row:
Adding rows is done with function key F21='Add Row' which creates a start and end element for the next free row. Deleting rows is done with function key F22='Delete row' which deletes the start element, the end element, and all the text elements between, for the row with the highest number.
Used to indicate the column number for the field in a layout. Within a row, the number must be unique. Column number is part of the element name. Changing the column number automatically updates the element name.
Used to indicate the space needed for the field in a layout. The default value is taken from the field length in the table.
Set to 'Cx', where 'x' is the column number (see Column number above).
If a field needs an additional label, it is defined by specifying an M3 message ID and Message file. If no Message file is specified, 'MVXCON' is used. The additional label is then included in the XML file translated to the correct language (based on user, customer, or supplier).
Specific fields may need to be disabled, so as not to be included in the XML file for the entire job. For example, the field 'VAT code' should only be included if VAT is used.
This is controlled by the parameter Run disabled. The decision if a field should be disabled is based on a virtual field from section type REPORT. If the virtual field is true (value 1), the field is considered to be disabled.
Alternatives for parameter Run disabled:
Format 3 - Open
For Open format, there is no additional functionality or other limitations.