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

Matchcode selection

Former Member
0 Likes
1,566

Hi all,

I´m trying to fill 3 fields when the user selects the matchcode help. I want to fill the fields after the first was selected, any ideas?

the code in the selection is:

SELECTION-SCREEN BEGIN OF BLOCK datosex WITH FRAME TITLE text-003.

PARAMETERS: fec_ini LIKE febmka-budtm DEFAULT sy-datum OBLIGATORY ,

fec_fin LIKE febmka-budtm DEFAULT sy-datum OBLIGATORY ,

c_banco LIKE t012k-hktid OBLIGATORY.

p_soc LIKE t012k-bukrs OBLIGATORY,

b_propio LIKE t012k-hbkid OBLIGATORY,

SELECTION-SCREEN END OF BLOCK datosex.

I want after the user selects c_banco with the matchcode, fill p_soc and b_propio.

Thanks for helping me!!

Gabriel P.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
992

Hi,

In the 'At selection-screen ON VALUE-REQUEST FOR p_soc' event (and also for b_propio): you need to call function 'DYNP_VALUES_READ' to capture the value of c_banco.

CALL FUNCTION 'DYNP_VALUES_READ'

EXPORTING

dyname = p_prog

dynumb = '1000'

TABLES

dynpfields = p_dt_read

Then, p_dt_read gives the selected c_banco value.

Then, select the values from T012K.

Then, call function 'DYNP_VALUES_UPDATE' to update the p_soc and b_propio values.

Another option is to:

Use 'DYNP_VALUES_READ' as before, but use the get/set parameters to update instead of 'DYNP_VALUES_UPDATE'. You may have to declare the p_sco and b_propio with a 'Memory ID XXX' addition.

Cheers,

Bhanu

4 REPLIES 4
Read only

Former Member
0 Likes
992

HI,

You can do this in initialization event.You capture the value entered in the c_banco & then use Function module F4_SEARCH_HELP.

Read only

Former Member
0 Likes
992

Hi,

You can create your match code object and assign to your selection parameter.

Method 1:

use SE11 transaction and create a collective search help and use in your program.

Metho2 : Use Initialization and use F4 help function module.

Message was edited by: Lanka Murthy

Read only

Former Member
0 Likes
993

Hi,

In the 'At selection-screen ON VALUE-REQUEST FOR p_soc' event (and also for b_propio): you need to call function 'DYNP_VALUES_READ' to capture the value of c_banco.

CALL FUNCTION 'DYNP_VALUES_READ'

EXPORTING

dyname = p_prog

dynumb = '1000'

TABLES

dynpfields = p_dt_read

Then, p_dt_read gives the selected c_banco value.

Then, select the values from T012K.

Then, call function 'DYNP_VALUES_UPDATE' to update the p_soc and b_propio values.

Another option is to:

Use 'DYNP_VALUES_READ' as before, but use the get/set parameters to update instead of 'DYNP_VALUES_UPDATE'. You may have to declare the p_sco and b_propio with a 'Memory ID XXX' addition.

Cheers,

Bhanu

Read only

0 Likes
992

Hi Bhanumurthy,

Thanks for answering, it worked fine, but is there a way to do it after I select the value for 'b_propio', I dont whant to do it by pressing F4 on 'c_banco'.

Thanks again

Message was edited by: Gabriel Fernando Pulido V.