Announcement

Collapse
No announcement yet.

Huge

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Huge

    Using PB/DOS 3.2. Can somebody explain to me why I get an
    error 9 (subscript out of range) on the line with the dim
    statement in this little program?

    Thanks.
    Maurice

    sub test
    dim HUGE keuze(1:38000) as local string
    end sub

    call test

  • #2
    In PB/DOS 3.2, HUGE arrays must have subscripts in the integer range of -32768 TO 32767 (ie, up to 65,535 subscripts).

    In PB/DOS 3.5, huge arrays can be anywhere in the LONG integer range (ie, up to 4,294,967,295 subscripts, but usually a lot less since they must fit into conventional memory!).

    PB/DOS 3.5 also supports VIRTUAL arrays (using EMS memory) and VIRTUAL arrays use the LONG integer range for subscripts, and each VIRTUAL array is limited to a whopping 32Mb.

    ------------------
    Lance
    PowerBASIC Support
    mailto:[email protected][email protected]</A>
    Lance
    mailto:[email protected]

    Comment

    Working...
    X