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: 

selection screen

Former Member
0 Kudos

Hi,

In My report,

I have 2 fileds 1st is material group and 2nd is material number.

I want

If I select the any material group in material group field,

I want in F4 ,all the material and its description under that group and material type will be FERT .

How can I do it.

Thanks

Kumar

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Kumar,

I think i clearly understood your requirement as follows...

If you select a particular Material Group, you need only that group Material num ber and its description in your Material Number field. Right?

Fo this you need to dynamically read the value of Material Group Field. For this you can make use of the FM - DYNP_VALUES_READ.

How to use this FM.

CLEAR: field_value.
  REFRESH dynpro_values.
  field_value-fieldname ='<Material Group>'.
  APPEND field_value TO dynpro_values.

* FM to Dynamically Read Values From Selection Screen Fields
  CALL FUNCTION 'DYNP_VALUES_READ'
    EXPORTING
      dyname             = sy-cprog
      dynumb             = sy-dynnr
      translate_to_upper = 'X'
    TABLES
      dynpfields         = dynpro_values.

*To Read the Dynamic Value.
  READ TABLE dynpro_values INDEX 1 INTO field_value.

After this you can write a querry with a where condition using the above fetched Material Group. Then use that FM for Search Help -- F4_IF_.....

5 REPLIES 5

Former Member
0 Kudos

Hi,

Go through the below link

[;

Former Member
0 Kudos

Hi,

Create a zsearch help according to your requirement and Use below function module:

F4IF_FIELD_VALUE_REQUEST

and use after the event:

at selection-screen on value-request for P_field.

Regards,

Former Member
0 Kudos

Hi Dear,

Please use the statement

At selection-screen on value Request for <Fieldname>

Then call the function module

Se37-

F4inthelp*

anyone u can use.

Enjoy.

Arbind

Former Member
0 Kudos

Hi kumar,

selection-screen begin of block b1 with frame title text-001.

select-options:plant for marc-werks no-extension , s_mtart for mara-mtart no-extension no intervals.

parameters : search(20) type c.

selection-screen end of block b1.

from mara-mtart table automatically you will get the F4 button (values list ).. I think so need of FM and search help...

  • waiting for your awards.

From maddy,

Former Member
0 Kudos

Hi Kumar,

I think i clearly understood your requirement as follows...

If you select a particular Material Group, you need only that group Material num ber and its description in your Material Number field. Right?

Fo this you need to dynamically read the value of Material Group Field. For this you can make use of the FM - DYNP_VALUES_READ.

How to use this FM.

CLEAR: field_value.
  REFRESH dynpro_values.
  field_value-fieldname ='<Material Group>'.
  APPEND field_value TO dynpro_values.

* FM to Dynamically Read Values From Selection Screen Fields
  CALL FUNCTION 'DYNP_VALUES_READ'
    EXPORTING
      dyname             = sy-cprog
      dynumb             = sy-dynnr
      translate_to_upper = 'X'
    TABLES
      dynpfields         = dynpro_values.

*To Read the Dynamic Value.
  READ TABLE dynpro_values INDEX 1 INTO field_value.

After this you can write a querry with a where condition using the above fetched Material Group. Then use that FM for Search Help -- F4_IF_.....