English

Error: AVArray: Index [number] not in range...

Error Message

Running the script "gps2shp.ave" returns:

"AVArray: Index [number] not in range..."

[number] can be any number.

Cause

Extra spaces in the points file can cause this error. These spaces may be found after the last record. The error occurs if the points file was created manually.

The script "gps2shp.ave" can be found in the ArcView Help > Contents > Sample scripts and extensions > Sample scripts > Views > Data conversion/alteration > Converts ASCII GPS output to shapefile.

Solution or Workaround

  1. Open the points file in a text editor.
  2. Remove extra spaces from the file.

    The file should be ASCII text in the form:

    Code:
    station id,x1,y1
    station id,x2,y2

  3. Press Enter after the last line.

    Warning:
    Avoid adding any extra spaces