This version is out of date, covering development from v5.0.0 to v5.12.2. It is maintained here only for inbound reference links from elsewhere.

Jump to the current version of aTbRef.

Tinderbox Icon

Number Data Type

Number

A numerical value. If no default value is specified, a Number type defaults to the value 0 (zero). User attributes of Number type may be configured, at first creation, as 'sequential'.

A sequential number attribute is like a database counter field, where the next unused number is issued and values no longer used are not re-issued; i.e. the next number is always higher than the last. Sequential numbers start at 1. When a new sequential attribute is added to an existing document, the already-created notes are initialised with sequential values of the new attribute, starting with the the first notes in $OutlineOrder sequence. Thereafter notes are numbered in the order added, regardless of $OutlineOrder.

Very large or small numbers may be displayed (and set) in exponential notation:

0.000001 = 1e-06 

$MyNum = 1.2e+3 sets '1200'

When very large or small number strings are typed into a key attributes box the result may be '0', in which case use exponential notation.

The key attribute display will also truncate the number of decimal places shown. The display limits seem to be:

When typing/pasting in number values to a KA box the input value is stored - not the rounded/truncated visible value. To see the decimal places in full coerce the value to a string, e.g. set a string attribute to the value of the number attribute. Beware that values copied from a key attribute display box use the visible value and not the real underlying value, so passing the number to a string and reading the latter is useful if data fidelity is required.

Listing of Number-type system attributes.


Possible relevant notes (via "Similar Notes" feature):


A Tinderbox Reference File : Objects & Concepts : Attributes: Data Types : Number Data Type