>My app is a multi user app. Early in the app a cursor is created when app is started. When the cursor is selected I do Index On field To tempindex. I have put several flags to fire to find out where the file access denied is happening. It seems to be after the select command and before the index on command. How can I prevent this when several users are logged on.
Try including the NOFILTER clause in the SQL statement that creates the cursor. If your SQL statement is not complicated, the resulting cursor will actually be just a filtered view of the table. You can't create an index on such a cursor. If that doesn't work try the following strategy:
SELECT ... INTO CURSOR Temp
USE DBF("Temp") IN 0 AGAIN ALIAS MyCursor
USE IN Temp
INDEX ON ...
The second line of code makes the cursor read-write, which you would need to do anyway if you wantd to create more than one index.
Brien R. Givens
Brampwood Systems