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: 

CJ20N - Transaction type

Former Member
0 Kudos

Hi everyone,

I have created few custom fields in CJ20N using SMOD: CNEX0007. My question is how can I find out the transaction type for this transaction - TRTYP = A / V so as to enable or disable the custom fields. I know this should be done in the PBO of screen exit. But, can you help me to identify the transaction type for the same.

Thanks in advance,

Hema

1 ACCEPTED SOLUTION

former_member215575
Active Participant
0 Kudos

In table TSTCA, transaction CJ20N has transaction type as 'A'.

Transaction types are available in TSTC table with field CINFO but will be in hexadecimal format which is '04' for CJ20N.

All the possible hexadecimal values defined for transaction types are found in standard program as below.

'00',             " Transaktion         T 

'01',             " Bereichsmenü        M

'02',             " Parametertrans.     P

'80',             " Report              R

'10',             " Report  mit Variante

'08',             " Objekttransaktionen

'04',             " mit Prüfobjekt         >> Google Translation in English 'with test object'

'20'.             " Gesperrt über SM01

Now it became difficult to correlate transaction types 'A' & '04', 41 being hexadecimal value for letter 'A'.!!

That's OK, I shall research more.. But answer to your question is 'A'.

6 REPLIES 6

former_member215575
Active Participant
0 Kudos

In table TSTCA, transaction CJ20N has transaction type as 'A'.

Transaction types are available in TSTC table with field CINFO but will be in hexadecimal format which is '04' for CJ20N.

All the possible hexadecimal values defined for transaction types are found in standard program as below.

'00',             " Transaktion         T 

'01',             " Bereichsmenü        M

'02',             " Parametertrans.     P

'80',             " Report              R

'10',             " Report  mit Variante

'08',             " Objekttransaktionen

'04',             " mit Prüfobjekt         >> Google Translation in English 'with test object'

'20'.             " Gesperrt über SM01

Now it became difficult to correlate transaction types 'A' & '04', 41 being hexadecimal value for letter 'A'.!!

That's OK, I shall research more.. But answer to your question is 'A'.

0 Kudos

Hi Sravan,

Thanks for the reply. Actually my question is : which variable in runtime tells me whether the TCODE : CJ20N is opened in change/display mode , like we have AKTYP = 'H' /'V' for purchase order. Based on the change/display mode I have to make the custom fields editable / non-editable.

Thanks in advance.

0 Kudos

Hi

Check for SAP_DISPLAY_ONLY in FM : EXIT_SAPLCJWB_002 , User Exit - CNEX0006.

SAP_DISPLAY_ONLY = 'X' for display

0 Kudos

Hi Atul,

I did try that option in the user exit earlier. But the constraint is, when i do "LOOP AT SCREEN" to disable some fields, the LOOP AT SCREEN doesn't loop through the screen elements. Instead, the control exit the loop. Thats the reason i chose to right it in PBO and looking forward to identify the transaction mode of the TCODE.

Any suggestions ?

Thanks,

Hema

0 Kudos

Hi - Please follow the steps and check if it helps you.

1. Declare a global variable (V_DISPLAY) in Top include ZXCN1TOP

2. Populate the field (V_DISPLAY) in include ZXCN1U21 (EXIT_SAPLCJWB_004) with the value of  SAP_DISPLAY_ONLY .

  Example :

CLEAR v_display.

   v_display = sap_display_only.

3. In Screen 700, Program SAPLXCN1, in the PBO,

LOOP AT SCREEN .

* Here check the value of V_DISPLAY and write your logic based on 'X' or space.

* if X , then its in display mode

ENDSCREEN.

Let us know, if it helps.

0 Kudos

Thank you Atul. Issue Solved