Sample program to unlock the editor of a program.

unlock sap program
Share on Facebook12Share on LinkedIn0Tweet about this on TwitterShare on Google+0
Please Share!!
TABLES: trdir.DATA: wa_trdir like trdir.PARAMETER: p_name like trdir-name.  ” Program name* Get program details
select single * from trdir into wa_trdir where name eq p_name.move space to wa_trdir-edtx.* Update the trdir table
CALL FUNCTION ‘RS_TRDIR_UPDATE’
EXPORTING
TRDIR_ROW             = wa_trdir
EXCEPTIONS
INTERNAL_ERROR        = 1
PARAMETER_ERROR       = 2
NOT_FOUND             = 3
OTHERS                = 4
.
IF SY-SUBRC eq 0.
write:/ ‘Editor unlocked successfully’.
ENDIF.

[adToAppearHere]

 

Image source : www.thefitnessbuddy.com

Share on Facebook12Share on LinkedIn0Tweet about this on TwitterShare on Google+0
Please Share!!

About the Author

SAP Yard
SAP Yard
SAPYard is one stop page for all Technical Folks in SAP. You would find un-conventional explanations, tutorials, and tricks. Please like our Facebook Page and also join our LinkedIn Group.

2 Comments on "Sample program to unlock the editor of a program."

  1. hi
    In sm12 sometimes we will unlock the program by delete the lock entries….so for this can we use this..if yes….i already tried it.but it is not working….let me know why..

    • Dear Krishna – You are confusing editor lock with sm12 lock. Both are two different things. To check if any program has editor lock, go to se38. Give program name and hit display or F7. From the menu GOTO->Attributes. Check four check boxes at the bottom. One of them is Editor lock.

      If I set the Editor Lock to one program, another developer would not be able to change it. This code snippet would remove that check.

      Hope this clarifies.

      If you still have question, please let us know.

      Regards,
      Team SAPYard.

Comments are closed.