Elo. What is the correct way to declare an array in a subroutine's parameters in FB? Is it possible to define the dimensions and size of the array when declaring it, as I can't find any help on this in the documentation. Currently I am using one like this:
sub drawimage (img_to_load())
size = ubound (img_to_load, 1)
...
end sub
I use UBOUND to determine the size of the passed array. A specific size for the parameter array isn't relevant to my current project, but is it possible to declare one?
'main
CLS
DIM the(0 TO 60) AS INTEGER
FOR i% = 0 TO 60 'just filling the array...
the(i%) = 5
NEXT i%
CALL test(the())
END
'sub
SUB test (thePassed%())
FOR i% = 0 TO 60 'dumping to screen to verify it worked.
PRINT thePassed%(i%)
NEXT i%
END SUB