Tab Function
Language Items List
Definition:
Used exclusively with the Print method to set the print position for the next
character to a specific column.
Syntax:
Tab(column)
Syntax Description
column Integer expression that is the column number of the new print position.
Details:
The leftmost print position on an output line is always 1.
When used with both forms and files, Tab operates as follows:
If the current print position is greater than the value specified by column, the print position first advances to the next line then moves to the
specified column.
If the value specified by column is less than the leftmost print position on an output line (1), the print
position moves to column 1.
When used with files only, Tab operates as follows:
If the value specified by column is greater than the designated print line width, Tab makes a calculation
based on the following: printposition = column Mod width.
If the value specified by column is less than the current print position, the print position advances to the
next line at the calculated print position.
If the calculated print position is greater than the current print position,
the print position is on the same line, but at the newly calculated print
position.
Be aware that the print positions are based on the average width of all
characters in the current font, size, and style being used. The correlation between
the number of characters printed and the number of fixed-width columns those
characters occupy is not one-for-one for this reason. The space the characters
will occupy varies based on your selected font, style, and size.