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

Drill Down...

Former Member
0 Likes
563

Hi, I have a parameter field in the selection-screen which takes the values as 'DAILY",'WEEKLY','MONTHLY' and 'QUATERLY'. I want to show all these values as drill down for that field.Please let me know how to achieve this? Thanks....

1 ACCEPTED SOLUTION
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
541

Can you explain a little better? Do you mean a listbox?



 report zrich_0005 .

type-pools: vrm.

parameters: p_val(20) type c as listbox visible length 20.

at selection-screen output.

  perform build_user_drop_down_list.

start-of-selection.

  write:/ p_val.

************************************************************************
* build user_drop_down_list
************************************************************************
form build_user_drop_down_list.

  data: name type vrm_id,
        list type vrm_values,
        value like line of list.

  clear list. refresh list.
  name = 'P_VAL'.


  clear value.
  value-key = 'D'.
  value-text = 'Daily'.
  append value to list.

  clear value.
  value-key = 'W'.
  value-text = 'Weekly'.
  append value to list.

  clear value.
  value-key = 'M'.
  value-text = 'Monthly'.
  append value to list.

  clear value.
  value-key = 'Q'.
  value-text = 'Quarterly'.
  append value to list.

* Set the values
  call function 'VRM_SET_VALUES'
    exporting
      id     = name
      values = list.

endform.       

Regards,

Rich Heilman

3 REPLIES 3
Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
542

Can you explain a little better? Do you mean a listbox?



 report zrich_0005 .

type-pools: vrm.

parameters: p_val(20) type c as listbox visible length 20.

at selection-screen output.

  perform build_user_drop_down_list.

start-of-selection.

  write:/ p_val.

************************************************************************
* build user_drop_down_list
************************************************************************
form build_user_drop_down_list.

  data: name type vrm_id,
        list type vrm_values,
        value like line of list.

  clear list. refresh list.
  name = 'P_VAL'.


  clear value.
  value-key = 'D'.
  value-text = 'Daily'.
  append value to list.

  clear value.
  value-key = 'W'.
  value-text = 'Weekly'.
  append value to list.

  clear value.
  value-key = 'M'.
  value-text = 'Monthly'.
  append value to list.

  clear value.
  value-key = 'Q'.
  value-text = 'Quarterly'.
  append value to list.

* Set the values
  call function 'VRM_SET_VALUES'
    exporting
      id     = name
      values = list.

endform.       

Regards,

Rich Heilman

Read only

FredericGirod
Active Contributor
0 Likes
541

Hi,

the simplest method I know is to create a data type refered to a domain.

In the definition of the domain you have a tab with the possible value.

You create the 4 values in the domain with description.

and in your report you could use the parameters (or the select-options) as :

parameters : p_toto type z_toto.

where z_toto is the data element you have created, point to the domain (for ex) z_toto (with the list of possible vlaue).

Rgd

Frédéric

Read only

Former Member
0 Likes
541

Hey Rich, thanks a lot. I think that has solved my problem.

Thanks...