cancel
Showing results for 
Search instead for 
Did you mean: 

Function module or search help !

former_member182354
Contributor
0 Kudos

Hi ABAP gurus,

I have a requirement where I have to have the Material, Sales Organization and Distribution channel displayed as parameters on one screen.

But the trick here is when ever I select any material .. The sales organization and distribution channel should only have values that only correspond to that material only.

Basically the Sales organization and Distribution channel should only have values corresponding to that material only in F4 help.. How to achieve this ..There should be some function module for this can anyone help me with this requirement .

Correct answer would be rewarded accordingly !

Regards,

Ragz

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Raghvendra,

try this.

AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_salesorg.

select salesorg from tablename into itab where matnr = p_matnr(selction screen value).

if sy-subrc eq 0.

CALL FUNCTION 'POPUP_WITH_TABLE_DISPLAY'

EXPORTING

ENDPOS_COL =

ENDPOS_ROW =

STARTPOS_COL =

STARTPOS_ROW =

  • TITLETEXT =

TITLETEXT =

IMPORTING

CHOISE = W_LINEN0

TABLES

VALUETAB = itab

EXCEPTIONS

BREAK_OFF = 1

OTHERS = 2.

IF SY-SUBRC EQ 0.

READ TABLE itab INDEX W_LINENO.

IF SY-SUBRC EQ 0.

P_salesorg = itab-salesorg.

endif.

endif.

similarly for distribution channel pass sales org ....

Former Member
0 Kudos

Hi,

This is what you can try to do....first select the sales org and distribution channel for the value entered in the material in an 2 separate internal tables.

Then use the FM 'F4IF_INT_TABLE_VALUE_REQUEST' for each internal table to get a search help for the sales org and distribution channel for any particular material number.

Please write the code at AT SELECTION-SCREEN ON VALUE-REQUEST event.

Hope it works,

Thanks,

Sandeep.

former_member182354
Contributor
0 Kudos

I think that will take a loong run time as I am doing a Dialog program for this !! Any function module which u know may be?