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 call transaction O4NSN by passing Nomination key (Without Parameter ID)

Former Member
0 Kudos

Hi experts, I will try to detail my problem as much as I can.

I'am working on an ALV, one of the cells is the Nomination key (information coming from OIJNOMI-NOMTK).

The requirement is when double clicking on the Nomination key we should call the transaction O4NSN and display the information about this Nomination key.

I tried with :

SET PARAMETER ID 'NOMTK'  FIELD ls_selfield-value.

CALL TRANSACTION 'O4NSN' AND SKIP FIRST SCREEN.

It didn't worked simply because the NOMTK has no Parameter ID.

Then I tried to record using the transaction se35 :

I got the following 3 messages :

So based on the last message, I tried again and I checked the Not a Batch Input Session Check-box.

It worked, and I got this

So I decided to use the CALL TRANSACTION 'O4NSN' USING lt_bdcdata .

          DATA : lt_bdcdata TYPE TABLE OF bdcdata.

          DATA : ls_bdcdata TYPE  bdcdata.

          ls_bdcdata-program = ''.

          ls_bdcdata-dynpro = ''.

          ls_bdcdata-dynbegin = 'T'.

         ls_bdcdata-fnam = 'O4NSN'.

          ls_bdcdata-fval = ''.

           APPEND ls_bdcdata TO lt_bdcdata.

And so on until I appended all the lines from the record to the internal table.

after double clicking on the nomination key from the ALV

I got the following 3 messages again :

the solution for this problem from the se35 transaction was to check the check box : Not a Batch Input Session.

Any idea how to do the similar using ABAP programming ?
Or any other proposition to how to How to call transaction O4NSN by passing Nomination key (Without Parameter ID) ?.

Thanks

1 ACCEPTED SOLUTION

ksouri_monta
Explorer
0 Kudos

Hello,

Please try this function module:  OIJ_MAINTAIN_NOMINATION with the user parameter 'nomtk'

IMPORT L_NOMTK FROM MEMORY ID 'nomtk'.

.

CALL FUNCTION 'OIJ_MAINTAIN_NOMINATION'

       EXPORTING

        it_oijnomh_key  = lt_oijnomh_key      " nomination number

        IV_DISPLAY_MODE = 'X'.


you can check this standard report also ROIJ_NOM_GUI


Best Regards

Montassar




2 REPLIES 2

ksouri_monta
Explorer
0 Kudos

Hello,

Please try this function module:  OIJ_MAINTAIN_NOMINATION with the user parameter 'nomtk'

IMPORT L_NOMTK FROM MEMORY ID 'nomtk'.

.

CALL FUNCTION 'OIJ_MAINTAIN_NOMINATION'

       EXPORTING

        it_oijnomh_key  = lt_oijnomh_key      " nomination number

        IV_DISPLAY_MODE = 'X'.


you can check this standard report also ROIJ_NOM_GUI


Best Regards

Montassar




0 Kudos

Dear Montassar,

Thanks for your help, it's working pretty fine ! that's exactly what I was looking for.

Kind Regards,

Mohamed Amine.