Hello
Actually we have no possibility to lock a part of the database in order to run some complex calculations. For this I've written a very small tool which helps to integrate a small lock messenger. The name of the class is TLegerLock and you find it in ICT\Petra\Server\lib\MFinance\GL\GL.CommonTools.cs
Typical constructor ...
TLegerLock tLegerLock = new TLegerLock(LedgerNumber);
Everone can unlook ...
tLegerLock.UnLock();
And the first lock results in a true and all the others in false ...
Assert.IsTrue(tLegerLock.Lock(), "Leger can be locked");
And in case of a conflict you can get the name of the user who locked the system and the date.
System.Diagnostics.Debug.WriteLine(tLegerLock.LockInfo());
Unfortunately there is no time information in the database.
Best regards
Wolfgang