Announcement

Collapse
No announcement yet.

Can array scan crash?

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

  • Can array scan crash?


    When i use a start index greater than the ubound of the array, can this be problem?
    My app GPF's but not always.


    ------------------
    hellobasic

  • #2
    Yes, absolutely. Your must ensure that any array subscript in use is always within the dimensioned array subscript range.

    Either that, or use #ERROR DEBUG ON, however it is much better to write "safe" code in the first place.

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

    Comment


    • #3
      When i use a start index greater than the ubound of the array..my app GPF's but not always.
      Patient, holding his right arm straight up in the air to demonstrate: "Doctor, when I do this, it hurts."

      Doctor: "Then don't do that."

      MCM


      Michael Mattias
      Tal Systems (retired)
      Port Washington WI USA
      [email protected]
      http://www.talsystems.com

      Comment

      Working...
      X