Delete Foreign Lock Entries in Debug
Delete/Release that lock entry and start working on that object immediately
Go to T-Code SM12. Provide the user id of the person who has locked the program and hit list.
You will get the list of all locks under his id.
Check you get the message, ‘You are not authorized to delete foreign lock entries‘.
You are in the debugger mode now.
Type sy-uname. You would find your user id by default.
Now, we just need to fool the system. In the sy-uname variable, replace your user id with the userid of the person who has locked this object.
You are done. You will get a pop up confirmation message. Just hit Yes. The lock entry is gone.
just replacing the sy-uname is the simplest way if you want to delete foreign locks.
Disclaimer: This page is not to encourage you to delete others locks. Please use it ethically and responsibly.