Hi, Parry:
I am not into VBA, so, in spreadsheets, I only work with formulas, basically.
I came up with BASIC, back in 1978, ending in QuickBASIC 4.5. I went on to Visual BASIC, but have reverted back to QuickBASIC.
As to spreadsheets, I started by learning Lotus 123, version "a" (if I remember correctly), back in 1983 or so, then ended with Excel.
Now, the integers straddled by the original 64K memory limit still stands in BASIC (DOS?), which allows integers from 0 to 32,767 (0 plus 32,767 positive numbers), and -1 to -32,768 negative numbers, for a total of 65,536 numbers.
In my VisualBASIC 6.0 (VB6), I can enter, directly, a number with up to 15 significant digits, and, I get all 15 significant digits in my INT() function, as in:
=INT(123456789012345), for which I see the answer as
123456789012345, or as in: =INT(1234567890123.45), which shows up as 1234567890123 (the whole 13 integer digits), and so on.
The exact, same thing as occurs in my VB6, above, also occurs in my Excel 97!
So, using the INT() function directly in the Excel spreadsheet seems to work for a 15-digit number in Excel, vs. a 16-digit number for long in BASIC and QuickBASIC). It seems that Excel uses "almost" long integers for its workings?
BASIC was justified in defining the simple integer and the long integer, because the first uses only 2 bytes, while the second used 4 bytes. And, in the early days, memory was very limited and programmers had to juggle their data, code and algorithms to be as small as possible, in order not to exceed the meager (64K, or 65,536 bytes) memory space available at the time.
Perhaps the 15-digit numbers are not used in VBA, VBA being a metamorphosis of the old BASIC, maybe still retaining the concepts of "integer" with 6 significant figures and the "long integer" with 16 significant figures? Or, perhaps, it is a form of VB6 or VB7.1, and also uses 15-digit-long "integers"?
It would be somewhat interesting, to me, to know if, indeed, VBA still uses simple integers and long integers. Sounds like an anachronism, to me, if it does. What do you think?