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: 

USER COMMAND in ALV

Former Member
0 Kudos

Hi friends,

Iam using At user command in ALV.. When iam double click its going to show the transaction Display.(example Invoice Number its showing Invoice Transaction).

But My requirement is i want double click on MBLNR(Material Document Number) Transaction Is MB03.. But I have to Pass the year also..

How i have tio give the input as year also..If i double click MBLNR..its should show the MB03 display Screen....

regards,

sampath

4 REPLIES 4

Former Member
0 Kudos

Hi,

Create a small recording of only the intital screen using SHDB transaction. Then pass this BDC table to CALL TRANSACTION (chk syntax for more details) and call in foreground mode. Here in the recording you will have to populate the MBLNR and YEAR.

I am assuming you have access to the YEAR in the ALV.

Thanks..

Preetham S

Former Member
0 Kudos

following code may help

DATA: BDCDATA TYPE TABLE OF BDCDATA.

DATA: ITAB TYPE TABLE OF BDCMSGCOLL.

DATA: PROGRAM LIKE SY-REPID,

WA_BDCDATA TYPE BDCDATA.

WA_BDCDATA-PROGRAM = 'SAPMS38M'.

WA_BDCDATA-DYNPRO = '0100'.

WA_BDCDATA-DYNBEGIN = 'X'.

APPEND WA_BDCDATA TO BDCDATA.

CLEAR WA_BDCDATA.

WA_BDCDATA-FNAM = 'RS38M-PROGRAMM'.

WA_BDCDATA-FVAL = PROGRAM.

APPEND WA_BDCDATA TO BDCDATA.

...

CALL TRANSACTION 'SE38' USING BDCDATA MODE 'N'

MESSAGES INTO ITAB.

reward if useful

S@meer

Former Member
0 Kudos

Hi sampathkumar,

1. Simple

2. Use PARAMETER ID (both for document number and YEAR).

3. like this.

SET PARAMETER ID 'MBN' FIELD '1234'.

SET PARAMETER ID 'MJA' FIELD '2007'.

CALL TRANSACTION 'MB03'

AND SKIP FIRST SCREEN.

Where 1234 = the document number

2007 = year

regards,

amit m.

Former Member
0 Kudos

hi

if u have the doc yr also displayed then i think u can go for chk boxes...

if that chk box is checked then u can pass those values from that internal table to the transation.....

hope iam clear...if any issue revert back