Form element
This table contains one row for each element in a form. The value in the Element type field determines which fields are filled out on each row.
| Property | Value | Description |
|---|---|---|
| Database | System | This table is in the system (vbsys) database. |
| SQL name | FormEl | The table name in the database. |
| API identifier | formElement | The API identifier used in GraphQL. |
| Table no. | 93 | The table number in the data model. |
The following fields exist in this table:
AutoReport tag
VAT code tag name in AutoReport XML.
See also: Configuring VAT forms
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | String of length 60 | Text (60) |
| SQL name | ArTag | The database field name. |
| API identifier | autoreportTag | The API identifier used in GraphQL. |
| Number | 17703 |
Background colour
The background colour of the form element.
Only relevant if you want to change the background colour of the text.
Is normally set using the colours dialog. The colours dialog can be found by pressing the * key on the keyboard or by double clicking in the field.
Press * or double-click to select colour.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Colour | Integer |
| SQL name | BCol | The database field name. |
| API identifier | backgroundColor | The API identifier used in GraphQL. |
| Number | 2232 |
Copy variant
The copy variant used.
- 1 - First copy
- 2 - Not first copy
- 3 - Last copy
- 4 - Not last copy
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Copy variant | Integer |
| SQL name | Var | The database field name. |
| API identifier | copyVariant | The API identifier used in GraphQL. |
| Number | 2039 |
Decimal type
The type of decimals.
Only relevant if you want to format the decimal type on the printout.
If the field is not filled in (has the value 0 in the database), the default decimals for the column in question are used.
- 0 - Default
- 1 - Fixed
- 2 - Floating
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Decimal type | Integer |
| SQL name | DcmTp | The database field name. |
| API identifier | decimalType | The API identifier used in GraphQL. |
| Number | 6661 |
Decimals
The number of fixed decimals.
Only relevant if you want to format the decimal field on the printout.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Number of digits | Integer |
| SQL name | Dcm | The database field name. |
| API identifier | decimals | The API identifier used in GraphQL. |
| Number | 6662 |
dx
The width of the form element.
Must be specified to display the form element correctly on the paper printout.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Margin | Integer |
| SQL name | dx | The database field name. |
| API identifier | dx | The API identifier used in GraphQL. |
| Number | 2042 |
dy
The height of the form element.
Must be specified to display the form element correctly on the paper printout.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Margin | Integer |
| SQL name | dy | The database field name. |
| API identifier | dy | The API identifier used in GraphQL. |
| Number | 2043 |
Element processing
Processings rules for the form element.
- No digit grouping symbol
- There will be no thousand separators on the printout. You must select this field for XML files because numbers with spaces are not accepted.
- Get Company data if empty
- Country and currency will be retrieved from the Company information table if it is missing from the order.
- Remove spaces
- All spaces will be deleted in the fields that you have entered in the Text/parameters field on the row. You can for example use bank account number and company number when you want to print these fields to an XML file.
- Remove all except numbers
- Everything except numbers will be deleted on the printouts.
- Omit on original printout
- The row will be excluded from the original printout. The row will then only be displayed when you print a copy of the order document from the Order document table. You can for example use the field to show that the printout is a copy by writing the text Copy on the row and selecting the option Omit on original printout.
- Omit on printout from order document table
- The row will be excluded when you print a copy of the order document from the Order document table. The row will only be shown on the original printout.
- Do not truncate/round decimals on VAT report
- The decimals in the VAT report will not be truncated.Note:This parameter must be used in countries where decimals shall be printed on VAT reports.
- Do not break line with pipe character
- When the option is checked, no line break will occur when a pipe character (a vertical bar, | ) appears in the field Text/parameters.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Element processing | Integer |
| SQL name | ElProc | The database field name. |
| API identifier | elementProcessing | The API identifier used in GraphQL. |
| Number | 6833 |
Element type
The type of element.
Must be specified to display the form element correctly on the paper printout.
- 0 - E-document
- Rows in the Form element table with the value 0 - E-document in the Element type field will be processed in connection with E-documents and will not be included in the Order document formula table.
- 1 - Text
You can use relationship operators and logical operators in the Text/parameters field.
Relationship operators (same as in SQL):- Equal to: =
- Greater than: >
- Less than: <
- Greater than or equal to: >=
- Less than or equal to: <=
- Different from: <>
Logical operators (same as in C++ and Java):- Negation (not): !
- Conjunction (and): &&
- Disjunction (or): ||
Evaluation order for parentheses and operators in the Text/parameters field:- Brackets
- Multiplicative operators (+, -, *, / and %)
- Additive operators (* and /)
- Relational operators (=, >, <, >=, <= and <>)
- Negation (!)
- Conjunction (&&)
- Disjunction (||)
- Conditions and partial expressions (? and :), see point 1498
Conditional formulae for form elements:- In the Text/parameters field in the Form element table, formulas (which start with an equals sign) can contain conditions and sub-expressions which are evaluated if the condition is true or false.
- The condition is followed by a question mark and the expressions are separated by a colon (in the same way as in C++ and Java).
= Condition ? Expression if the condition is true: Expression if the condition is false:- The conditions can have an almost unlimited number of levels, using parentheses.
- The entire composite expression is entered in the relevant field.
Example of two levels:- = Condition 1 ? ( Condition 2 ? Expression which will be evaluated if conditions 1 and 2 are true. : Expression which will be evaluated if condition 1 is true but not 2. ) : Expression to be evaluated if condition 1 is false.
- ? and : have the lowest priority of all operators and have been added at the end of the listings of evaluation order in points 1464 and 1478.
This is an alternative to using IF, ELSEIF, ELSE and ENDIF in the Element type field where a numerical value is to be returned.
- 2 - Line
- Graphic line
- 3 - Rectangle
- Graphic rectangle
- 4 - Rounded rectangle
- Graphic rounded rectangle
- 5 - Oval
- Graphic circle
- 6 - Bitmap
- Is an image file
- 7 - IF
Conditional execution of form elements:
With IF and ELSEIF, the condition must be specified in the Text/parameters field on the row.
IF, ELSEIF and ELSE must be followed by one or more form elements which will be executed if the condition is true or false in the case of ELSE.
For each IF, there can be 0 or more ELSEIF's, 0 or 1 ELSE, and there must be 1 ENDIF.
Using ELSEIF merges ELSE and a following IF and eliminates the need for an extra ENDIF.
(If the program encounters an ELSEIF, ELSE or ENDIF without a preceding IF, the drawing of the form is stopped.)
When using conditional execution of form elements with element type IF and ELSE IF in the Form element table where the condition involves a varchar field and the comparison value is an empty string it is necessary to enclose the comparison value in double quotes (").
Example: @Order (Your ref.)<>""
The control structures can have an almost unlimited number of levels.
Example of two levels:
IF Condition 1 Form elements which will be executed if condition 1 is true.
IF Condition 2 Form elements which will be executed if condition 2 is true.
ELSEIF Condition 2B Form elements which will be executed if condition 2 is false, and 2B is true.
ELSE
Form elements which will be executed if the condition(s) is/are false.
ENDIF ELSEIF Condition 1B Form elements which will be executed if condition 1 is false, and 1B is true.
ELSE
Form elements which will be executed if the condition(s) is/are false.
ENDIF
If sentences can test whether a field is blank or whether data has been entered in the field. For example, you could have two address lines in the form on your order documents. If a customer has only used one of these, the blank line can be suppressed and not printed out.
Example: You select 7 - IF in the Element type field and type @Order(Address line 2)= in the Text/parameters field.
- 8 - ELSEIF
- 9 - ELSE
- 10 - ENDIF
- 11 - Company dependant picture 1
The selections 11 - Company dependant picture 1 and 12 - Company dependant picture 2 are used to show a picture which depends on the type of company that the printout has been prepared for.
The Text/parameters field is used to specify a variable name (without using the macro function) which refers to a row in the Text company variable table, where the same value is entered in the Variable name field. The picture file's path/file name is inserted in the Value 1 or Value 2 field for 11 - Company dependant picture 1 and 12 - Company dependant picture 2 respectively.
The Namespace field must also be filled out, with identical values in the Form element and Text company variable tables. Lookups in this column lead to the Namespace table.
Until further notice only BMP files will be used in forms.
By not specifying dx and dy for these form elements, the original width and height of the picture file will be used.
- 12 - Company dependant picture 2
- 13 - Image (Business NXT only)
The selection 13 - Image (Business NXT only) is used to print a company dependent image.
The image file is added from the Integer company variable table.
Additional setup needed for linking to the correct row in the Integer company variable table:- The Namespace field - the same value as the Namespace field in the Integer company variable table
- The Text/parameters field - the same value as the Variable name field in the Integer company variable table
By not specifying dx and dy for these form elements, the original width and height of the picture file will be used.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Element type | Integer |
| SQL name | ElTp | The database field name. |
| API identifier | elementType | The API identifier used in GraphQL. |
| Number | 2089 |
Font
The text font.
The field shows the font family, style and size within square brackets. In the database there are three separate fields for font family, font style and font size. The field shown on the screen keeps the font size in the database.
The font size may be set as a percentage (e.g. 120) of the normal font size, cf. the Relative option in the Type drop-down list in the dialog box.
Is normally set with the Font command (in the Design group in the Home tab).
You can also specify the font size using the graphical editor. The graphical editor can be found using the processing Graphical editing from the Form table.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Font | Integer |
| SQL name | FSz | The database field name. |
| API identifier | fontSize | The API identifier used in GraphQL. |
| Number | 2047 |
Foreground colour
The foreground colour of the form element.
Only relevant if you want to change the foreground colour of the text.
Press * or double-click to select colour.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Colour | Integer |
| SQL name | FCol | The database field name. |
| API identifier | foregroundColor | The API identifier used in GraphQL. |
| Number | 2231 |
Form no.
The form number.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Form no. | Integer |
| Primary key | Yes | Form type, Form no., Line no. |
| SQL name | FormNo | The database field name. |
| API identifier | formNo | The API identifier used in GraphQL. |
| Number | 2037 |
Form type
The form type.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Form type | Integer |
| Primary key | Yes | Form type, Form no., Line no. |
| SQL name | FormTp | The database field name. |
| API identifier | formType | The API identifier used in GraphQL. |
| Number | 2036 |
Justification
How the form element is justified. In this field you enter the justification method for the form element.
Must be specified to display the form element correctly on the paper printout.
- 1 - Left justified
- 2 - Centred
- 3 - Right justified
- 4 - Left justified header
- 5 - Centred header
- 6 - Right justified header
- 7 - Left justified footer
- 8 - Centred footer
- 9 - Right justified footer
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Justification | Integer |
| SQL name | Just | The database field name. |
| API identifier | justification | The API identifier used in GraphQL. |
| Number | 2045 |
Line no.
Each line in the table is given a consecutive number in the order in which they are entered.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | No. | Integer |
| Primary key | Yes | Form type, Form no., Line no. |
| SQL name | LnNo | The database field name. |
| API identifier | lineNo | The API identifier used in GraphQL. |
| Number | 2038 |
Line thickness
The line thickness shown in pixels.
Only relevant if you need lines in the paper printout e.g. when doing mathematical calculations.
- Invisible
- Single
- Double
- Other
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | No. | Integer |
| SQL name | LnTn | The database field name. |
| API identifier | lineThickness | The API identifier used in GraphQL. |
| Number | 2230 |
Namespace
Refers to the Namespace table.
The Namespace field is used to get the correct path to the picture file name.
The namespace value will be applied as a prefix to the local text found in the Text/parameters field.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | GUID | Text (40) |
| SQL name | NmSp | The database field name. |
| API identifier | namespace | The API identifier used in GraphQL. |
| Number | 10785 |
| To table | Purpose | From columns | To columns | Comments |
|---|---|---|---|---|
| Namespace | Namespace |
|
Page variant
The location of the form element on the printout.
Only relevant if form element is to be printed on a specified page.
- 1 - First page
- 2 - Not first page
- 3 - Last page
- 4 - Not last page
- 5 - Giro element on last page
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Page variant | Integer |
| SQL name | PgVar | The database field name. |
| API identifier | pageVariant | The API identifier used in GraphQL. |
| Number | 2246 |
Sort seq. no.
The order of the lines.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Sort seq. no. | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | Srt | The database field name. |
| API identifier | sortSequenceNo | The API identifier used in GraphQL. |
| Number | 2090 |
Style
- Bold
- Italic
- Underline
- Strike through
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Style | Integer |
| SQL name | FSt | The database field name. |
| API identifier | fontStyle | The API identifier used in GraphQL. |
| Number | 2048 |
Text/parameters
You can enter text or fields from the database that will be printed in the form element in the dialog box that appears when you double-click in the field.
Must be specified to display the form element correctly on the paper printout.
- @SystemInteger (Variable name, element no.)
- @SystemDecimal (Variable name, element no.)
- @SystemText (Variable name, element no.)
- @FirmInteger (Variable name, element no.)
- @FirmDecimal (Variable name, element no.)
- @FirmText (Variable name, element no.)
Element no. is in the 1 - 12 range for integer and decimal variables and the 1 - 2 range for text variables. The parameter can be omitted and will then be given the value 1. Remember to specify Namespace on the rows.
- @Selection You can use the @Selection macro to print the current selection. The selection is shown in plain text and not as SQL code, and in the sequence defined in the selection dialog box. The macro @Selection will display the field, operator and value. If the selection criteria do not fit on a line, you can increase the dy value to break the line.
- @Sort You can use the @Sort macro to print the current sorting. The sorting is shown in plain text and not as SQL code, and in the sequence defined in the sorting dialog box. The sorting is shown with numbering and AZ or ZA for ascending or descending sorting. The @Sort macro does not display subtotals.
In the macro function @GiroAmountAsText() you can enter the currency designation you require in brackets.
See Formula for more information about the macro functions.
Example
@GiroAmountAsText(Eur,Cent) - This text is displayed instead of the one that is hard-coded for the currency in question. This is implemented for the languages Norwegian, Swedish, Danish, German and Lithuanian. You select the language for the macro @GiroAmountAsText() in the Cheque amount text field in the Company information table.| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Macro functions | Text (500) |
| SQL name | Txt | The database field name. |
| API identifier | textOrParameters | The API identifier used in GraphQL. |
| Number | 2044 |
Type
The font name.
- Arial
- Courier New
- Lucida Console
- Segoe UI
- Times New Roman
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Type | Text (64) |
| SQL name | FFm | The database field name. |
| API identifier | fontName | The API identifier used in GraphQL. |
| Number | 2046 |
x
The distance to the left-hand edge of the form.
Must be specified to display the form element correctly on the paper printout.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Margin | Integer |
| SQL name | x | The database field name. |
| API identifier | x | The API identifier used in GraphQL. |
| Number | 2040 |
XML level
This field is no longer in use. Be aware the field may be removed in later versions.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | No. | Integer |
| SQL name | XMLlvl | The database field name. |
| API identifier | xmlLevel | The API identifier used in GraphQL. |
| Number | 12028 |
XML tag
Used for mapping the macro to the XML tag name. All names must be unique and defined in the same manner as the default layouts. At present, the field is only used for the Visma XML format and Altinn.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | String of length 60 | Text (60) |
| SQL name | XMLTag | The database field name. |
| API identifier | xmlTag | The API identifier used in GraphQL. |
| Number | 12027 |
y
The distance to the upper edge of the form.
Must be specified to display the form element correctly on the paper printout.
| Property | Value | Description |
|---|---|---|
| Visible by default | Yes | This field is visible by default in the table display. |
| Domain | Margin | Integer |
| SQL name | y | The database field name. |
| API identifier | y | The API identifier used in GraphQL. |
| Number | 2041 |
Control columns
Control columns include information about who has changed the record last and when, and which process that is currently editing the record.
Changed by provenance
The provenance for the record change.
A look-up in this field gives you the following list of possible values:
0 - None
1 - UI
10 - External API
20 - GAiA
21 - AI Connect
100 - Internal service
101 - Task automation
102 - AutoInvoice download
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Provenance | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | ChPvn | The database field name. |
| API identifier | changedByProvenance | The API identifier used in GraphQL. |
| Number | A unique column number. |
Changed by user
The name of the user that changed the record.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | User name | Text (24) |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | ChUsr | The database field name. |
| API identifier | changedByUser | The API identifier used in GraphQL. |
| Number | A unique column number. |
Changed date
The date when the record was changed.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Date | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | ChDt | The database field name. |
| API identifier | changedDate | The API identifier used in GraphQL. |
| Number | A unique column number. |
Changed time
The time when the record was changed.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Time | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | ChTm | The database field name. |
| API identifier | changedTime | The API identifier used in GraphQL. |
| Number | A unique column number. |
Changed time stamp
The date and time when the record was changed.
The field is updated with the UTC time.
This value can be used by external systems to replicate changed data. The column is indexed.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Date/time | DateTime |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | ChTs | The database field name. |
| API identifier | changedTimestamp | The API identifier used in GraphQL. |
| Number | A unique column number. |
Created by provenance
The provenance for the record creation.
A look-up in this field gives you the following list of possible values:
0 - None
1 - UI
10 - External API
20 - GAiA
21 - AI Connect
100 - Internal service
101 - Task automation
102 - AutoInvoice download
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Provenance | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | CrePvn | The database field name. |
| API identifier | createdByProvenance | The API identifier used in GraphQL. |
| Number | A unique column number. |
Created by user
The name of the user that created the record.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | User name | Text (24) |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | CreUsr | The database field name. |
| API identifier | createdByUser | The API identifier used in GraphQL. |
| Number | A unique column number. |
Created date
The date when the record was created.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Date | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | CreDt | The database field name. |
| API identifier | createdDate | The API identifier used in GraphQL. |
| Number | A unique column number. |
Created time
The time when the record was created.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Time | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | CreTm | The database field name. |
| API identifier | createdTime | The API identifier used in GraphQL. |
| Number | A unique column number. |
Created time stamp
The date and time when the record was created.
The field is updated with the UTC time.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Date/time | DateTime |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | CreTs | The database field name. |
| API identifier | createdTimestamp | The API identifier used in GraphQL. |
| Number | A unique column number. |
Edit status
The current status of the record.
A look-up in this field gives you the following list of possible values:
0 - Unchanged: The record is read, but not changed.
1 - Inserted: The record is new.
2 - Changed: The record is changed.
3 - Deleted: The record is deleted.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Edit status | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | LckSt | The database field name. |
| API identifier | editStatus | The API identifier used in GraphQL. |
| Number | A unique column number. |
Process no
The Process no. from the Active company process table which is currently using or has control of this record.
| Property | Value | Description |
|---|---|---|
| Visible by default | No | This field is not visible by default in the table display. |
| Domain | Process no. | Integer |
| Write Access | None | You are not allowed to modify the value in this field. |
| SQL name | ChPrc | The database field name. |
| API identifier | lockedByProcessNo | The API identifier used in GraphQL. |
| Number | A unique column number. |
| To table | Purpose | From columns | To columns | Comments |
|---|---|---|---|---|
| Active company process | CompanyProcess | Process no. | Process no. |