Error 105 - file lock AR_CashReceiptsjournal.upd

we are running Sage 100 Standard version 2017

Had an issue where one user was doing Auto Generate Invoices Selection and another was doing Cash Receipts at the same time.

Here are the two error msg's received.

AR person received the error 105 keyed file error , Program AR_CASHRECEIPTSJOURNAL_UPD, class: AR_CashReceiptsJournal_upd,  Method: UpdateCashReceiptsHistory

Invoice person received the error 105 Keyed file error, Program CI_UPDATEHEADERTOAR.PVC ,Class SO_SalesJournal_upd , method:WriteTransPostHist

this corrupted AR files that had to be rebuilt.  is there any way to do a file lock exclusive so that when one person is doing an update it locks everyone out until that process is done and then the other person can proceed?

or is there another way to do these procedures as to not interfere with each other where it corrupts the files?