comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » error: subscript range values of the form low:high must be >= 0, < size
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
error: subscript range values of the form low:high must be >= 0, < size [message #63194] Fri, 31 October 2008 10:34 Go to previous message
frankosuna is currently offline  frankosuna
Messages: 31
Registered: February 2008
Member
I am trying to store values into a array of type long but I keep
getting the following error:
subscript range values of the form low:high must be >= 0, < size, with
low <= high: ROIPIXELS.
The weird thing about it is when I set a breakpoint and step through
the code it doesn't throw the error anymore. Also, if instead I don't
use numClicks as the index and hardcode a 0 or 1 or 2...etc the code
works as well!!!

HELP!!!!!!!!!

roiPixels = LONARR(5,25)
numClicks = 1

WHILE(!mouse.button NE 4) DO BEGIN
CURSOR, xi, yi, /DEVICE
IF(!mouse.button EQ 1) THEN BEGIN
x = LINDGEN(5*5) MOD 5 + xi
y = LINDGEN(5*5) / 5 + yi
roiPixels[numClicks,*] = x + y * 1024
numClicks++
ENDIF
ENDWHILE
[Message index]
 
Read Message
Read Message
Previous Topic: Re: Multiple click region growing
Next Topic: Coyote as Mac User

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 17:59:57 PDT 2025

Total time taken to generate the page: 1.68023 seconds