Application Development and Automation 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: 
Read only

need code logic

Former Member
0 Likes
370

Hi

I need help in interactive ALV Repot. When i executed the report, it is displaying the material Doc number ,material etc in grid layout.

my requirement is , when i double click on material Document number , it has to show the sales order number, salesorder item and Delivery number. Same thing is required for when i click on material also.

please help me in this.

regards,

Ram

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
349

Hi

see the sample code for one field double clicking

FORM user_command USING r_ucomm LIKE sy-ucomm

rs_selfield TYPE slis_selfield.

DATA: index TYPE i,

w_disp_head LIKE LINE OF t_disp_head,

w_door LIKE likp-lgtor.

CASE r_ucomm.

WHEN 'PICK'. " Double click line

IF ( rs_selfield-fieldname = 'MBLNR' or

rs_selfield-fieldname = 'MATNR' ).

  • Read data table, using index of row user clicked on

Read the internal table in which these fields are there.

take that records corresponding EBELn and EBELP fields for that MATNR or MBLNR fields

READ TABLE t_disp_tab INTO wa_item_tab INDEX

rs_selfield-tabindex.

fetch the sales order no and item data from EKKN table by passing the PO no and PO item

<wa_item_tab-ebeln and wa_item_tab-ebelp>

display the data using an internal table or in another ALV.

endcase.

endform..

Reward points if useful

Regards

Anji

2 REPLIES 2
Read only

Former Member
0 Likes
349

Hi Ram,

u need to use Hotspot, Hide statements to work on interactive reports.

when u post the code we can better help u more...

check this thread for reference.....

Regards

SAB

Read only

Former Member
0 Likes
350

Hi

see the sample code for one field double clicking

FORM user_command USING r_ucomm LIKE sy-ucomm

rs_selfield TYPE slis_selfield.

DATA: index TYPE i,

w_disp_head LIKE LINE OF t_disp_head,

w_door LIKE likp-lgtor.

CASE r_ucomm.

WHEN 'PICK'. " Double click line

IF ( rs_selfield-fieldname = 'MBLNR' or

rs_selfield-fieldname = 'MATNR' ).

  • Read data table, using index of row user clicked on

Read the internal table in which these fields are there.

take that records corresponding EBELn and EBELP fields for that MATNR or MBLNR fields

READ TABLE t_disp_tab INTO wa_item_tab INDEX

rs_selfield-tabindex.

fetch the sales order no and item data from EKKN table by passing the PO no and PO item

<wa_item_tab-ebeln and wa_item_tab-ebelp>

display the data using an internal table or in another ALV.

endcase.

endform..

Reward points if useful

Regards

Anji