>>Is it possible that they are running it on two PCs at the same time?
>
>It's a multiuser system, so there might be 10 or 20 users on at the same time, but the exe and data files are on the network, so they are all accessing the same exe and the same user and other data tables. The thing is that some of the user records that seem to be locked belong to users who are still listed in the user table, but in fact are no longer with the company and may not have been on the system for months. Others in the 'currently logged in' list might not have logged into the system for days. 10 minutes later some of them might no longer show in the list. But tomorrow they might again (without having logged in).
Sorry I wasn't clear. Is it possible that they are running the code you posted on two or more PCs at the same time?
--sb--