> Can somebody please tell why this small sexy program
> crushes when it calls DmResetRecordStates?
>
> Without DmResetRecordStates, it works fine.
>
Because DmResetRecordStates has a bug.
>From an earlier posting by Bob Ebert:
> DmResetRecordStates has a bug. It doesn't unprotect the storage heap
> itself (a la DmWrite) so when it tries to unbusy a record, it generates the
> error you see because it's trying to write to protected memory.
>
> Normally it's only called from DmOpenDatabase, and the fact that it's
> called from another data manager routine that's already unprotected the
> storage heap masked the problem from detection.
>
> That said, you really shouldn't be calling DmResetRecordStates. Make sure
> you clean up your records as you use them -- it's much safer and will
> improve performance. DmResetRecordStates was intended for the OS to use
> during error recovery.
>
> --Bob
--
Neil Rhodes
Calliope Enterprises, Inc.
1328 Clock Avenue
Redlands, CA 92374
(909) 793-5995 [EMAIL PROTECTED] fax: (909) 793-2545