>Hello people,
>I have had a problem with Adir(). I am trying create a array with all files JPG in one diretory. This directory have 15383 images. Whem I create this array, fox give me this message: "Invalid Subscript reference".
>What I can do to read all files in this directory?
>
>Thanks!
>
>Rômulo
You can use the SYS(2000) function and a loop to put all of your filenames in a cursor or in an array, as long as you don't exceed 65000 total array elements. A cursor wouldn't have any practical limit. The ADIR() function fails because it returns a 5 elements for each file, so you can have a maximum of 13000 files (13000*5=65000).