02-03-2024, 10:03 PM
(02-03-2024, 08:54 PM)bartok Wrote: As you can see, I'm in the mood for questions.
Look at this:
Code: (Select All)
OPTION _EXPLICIT
DIM myArray%(5)
PRINT UBOUND(myArray%)
the result is "5".
Fine.
Look at this:
Code: (Select All)
OPTION _EXPLICIT
DIM myArray%
PRINT UBOUND(myArray%)
This is less "fine".
1. If OPTION_EXPLICIT is activeted, it says "myArray" is not defined.... why?
2. If OPTION_EXPLICIT is deactiveted, the result is "10"... why?
DIM myArray% is only a varaible NOT an array it needs the () for an array Ubound can make sense of.
724 855 599 923 575 468 400 206 147 564 878 823 652 556 bxor cross forever

