Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to unlock the Editor Lock?

Former Member
0 Kudos

Hi All,

Can anyone tell how to unlock Editor Lock?

Thanks in advance.

Regards

Mohammad.

1 ACCEPTED SOLUTION

ferry_lianto
Active Contributor
0 Kudos

Hi Mohammad,

Please check this sample program.

REPORT ZEDITOR. 

TABLES: TRDIR. "System table TRDIR 

PARAMETERS: PROGRAM LIKE TRDIR-NAME. 
PARAMETERS: EDITOR  LIKE TRDIR-EDTX. 

SELECT SINGLE * FROM TRDIR WHERE NAME = PROGRAM. 

TRDIR-EDTX = EDITOR. 
MODIFY TRDIR. 
IF SY-SUBRC EQ 0. 
   WRITE: / 'Editor Lock update Successful ', TRDIR-NAME. 
   IF TRDIR-EDTX = 'X'. 
      WRITE: ' Lock'. 
   ELSE. 
      WRITE: ' UnLock'. 
   ENDIF. 
ELSE. 
   WRITE: / 'Editor Lock update Unsuccessful ', TRDIR-NAME. 
ENDIF.

Hope this will help.

Regards,

Ferry Lianto

Please reward points if helpful.

6 REPLIES 6

Former Member
0 Kudos

Hi,

The attributes of the program has the Editor Lock flag..

But this can be checked or unchecked only by the one user and the owner.

Others wont be allowed to change the contents of the program..

Regards,

Tanveer.

<b>Please mark helpful answers</b>

ferry_lianto
Active Contributor
0 Kudos

Hi Mohammad,

Please check this sample program.

REPORT ZEDITOR. 

TABLES: TRDIR. "System table TRDIR 

PARAMETERS: PROGRAM LIKE TRDIR-NAME. 
PARAMETERS: EDITOR  LIKE TRDIR-EDTX. 

SELECT SINGLE * FROM TRDIR WHERE NAME = PROGRAM. 

TRDIR-EDTX = EDITOR. 
MODIFY TRDIR. 
IF SY-SUBRC EQ 0. 
   WRITE: / 'Editor Lock update Successful ', TRDIR-NAME. 
   IF TRDIR-EDTX = 'X'. 
      WRITE: ' Lock'. 
   ELSE. 
      WRITE: ' UnLock'. 
   ENDIF. 
ELSE. 
   WRITE: / 'Editor Lock update Unsuccessful ', TRDIR-NAME. 
ENDIF.

Hope this will help.

Regards,

Ferry Lianto

Please reward points if helpful.

0 Kudos

wanna give Ferry rewards. can't i?

sooo helpful!

0 Kudos

Appreciated

Former Member
0 Kudos

This message was moderated.

Former Member
0 Kudos

This message was moderated.