It's bug fix in VFP9SP2: "VFP allows to create structural CDX for a table opened in shared mode, which may cause header corruption". You have to open table exclusivelly in order to create structural index.
>I'm working on an old app that runs without errors in production (VFP 9 runtime) but is giving me an error when I run it in VFP9 SP2.
>
>I am creating a temporary file, and then creating an index for it.
>
>Example:
>
>Select ... into DBF filename
>USE filename
>Index on fieldname tag indexname
>
>I get the "File must be opened exclusively" error.
>
>So far, the only difference I can find is SP1/SP2. Is this a SP2 issue?
>
>Thanks,
>Larry Morelli
--sb--