>Hi Jimi Lee
>
>You can use the following code the Automatically Re-Index the Table, U could fine tune as per your requirement.
>
> TDBF=ADIR(DATAF,"*.DBF")
> FOR I=1 TO TDBF
> Filereindex=DATAF(I,1)
> Use DATAF(I,1) EXCLUSIVE
> If Used()
> Reindex
> Endif
> ENDFOR
Zaheer. Jimi is asking how to check if an index is corrupted - not how to reindex it. I dont think there is a sure fire way to do this though. VFP8 has an additional level of file header checking but not sure about knowing if the entire index is 100% OK.
There are a couple of utilities here in the UT download section which you might be able to use and possibly incorporate into a maintenance app. See
ATFixDbfFpt 1.5a, all xBases supported. File #
9930and
Crashed tables rebuilder File #
9264
In the End, we will remember not the words of our enemies, but the silence of our friends - Martin Luther King, Jr.