0

In this event I am throwing message

AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_vari.
  CLEAR g_variant.
  PERFORM set_variant.

  IF g_msg IS NOT INITIAL.
    MESSAGE g_msg TYPE 'S' DISPLAY LIKE 'E'.
  ENDIF.**

And here I have two select option and a parameter in different block.

AT SELECTION-SCREEN ON BLOCK group.
  CLEAR g_msg.
  IF s_prg IS INITIAL AND s_wbs IS INITIAL.
    CONCATENATE g_msg  text-002 INTO g_msg SEPARATED BY space.
  ELSEIF s_prg IS NOT INITIAL AND s_wbs IS NOT INITIAL.
    CONCATENATE g_msg  text-003 INTO g_msg SEPARATED BY space.
  ENDIF.

AT SELECTION-SCREEN ON p_vari.
  CLEAR: g_esito.
  PERFORM check_vari CHANGING g_esito
                              g_msg
                              g_variant.

I would like to see the message of the parameter p_vari if the select options are valued. I would not like to see the message when I use the select option match code.

Suncatcher
  • 10,355
  • 10
  • 52
  • 90
stella
  • 51
  • 2
  • 5
  • 13
  • 2
    Please provide a [minimal **reproducible** example](https://stackoverflow.com/help/minimal-reproducible-example) (your code doesn't compile), explain what "don't work correctly" means i.e. [what you expect and what it does currently, and what you have tried](https://stackoverflow.com/help/how-to-ask). – Sandra Rossi Sep 25 '19 at 05:31
  • You should read about the [order of selection-screen events](https://help.sap.com/saphelp_47x200/helpdata/en/56/1eb6c705ad11d2952f0000e8353423/content.htm?no_cache=true). – Legxis Sep 25 '19 at 09:26

1 Answers1

2

try simply at-selection-screen statement to validate parameters and throw messages if necessary. it should work, but unfortunately I do not have the knowledge to explain why.

Pedro Accorsi
  • 765
  • 1
  • 8
  • 21