‎2007 Apr 30 3:12 AM
Hi,
if some user is using VA02 tcode.i want to know for which sales order(i.e Sales order number)he is making changes.
i want ABAP code sample for this scenario.
Cheers,
Jag
‎2007 Apr 30 3:25 AM
Hi,
You can use the FM ENQUEUE_READ function module..
Give the user name..
In the parameter
GUNAME - GIve the user ID.
GNAME - VBAK
In the ENQ internal table you will have a list of sales orders that the user is using in VA02.
Thanks,
Naren
‎2007 Apr 30 4:12 AM
Hi,
For this you need to create Lock Object from se11 .It will automatically crate Two Function modules for enque and deque.
In you case If you want to see the Details for Va02 use.
CALL FUNCTION 'ENQUEUE_EVVBAKE'
EXPORTING
VBELN = VBELN
EXCEPTIONS
FOREIGN_LOCK = 1
SYSTEM_FAILURE = 2.
CASE SY-SUBRC.
WHEN 1.
MESSAGE E042(V1) WITH vbeln RAISING ERROR_IN_COPY.
ENDCASE.
Regds,