>How can I programatically Know if one is using a particular table in the database. I have a stock taking program that only works for a user at a time.
You can try to use the table exclusively and trap the error
on error store .T. to InUse
use MyTable in 0 exclusive
if InUse
endif
Don't forget to save and restore the previous on error.
HTH
Caroline