• If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Announcement

Collapse
No announcement yet.

NAB : how to check for record locking ??

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • NAB : how to check for record locking ??

    I'm in the process of creating a new NAB application.. initially showing a grid with records, (outstanding orders) where the user needs to click -on and start doing some processsing
    (going to another section in Nab)

    The app will be usable from multiple people viewing the same data.

    I want to avoid that persons start working on a record, if it is already 'in-use' with another person..


    idea : best would be to fade on the overview grid the record, where another person is already working on .. ideally with a 'hoover' message indicating that person that has the record in use..


    other option could be to check when they click the row-grid, then first checking the lock-file , and possibly returning an message if locked, before continuing processing



    i'm curious to know if there is a best-practice to solve this record locking

    any idea is welcome

    Thx

    Thierry

  • #2
    I would suggest you attach a "Call RPG Program" action to the row click of your grid.
    Then on the "success=true" add your subsequent actions.

    Your RPG would be something as follows:
    Code:
    if LockRecord();
      SetResponse('success':'true');
     else;
      SetResponse('success':'false');
      SetResponse('info':'This record is locked by user XXXX');
    endif;

    Comment

    Working...
    X