Skip to Content

Warning message of variant configuration

Hi, experts.

I have an issue with the function of variant configuration.

I would like to set a warning message when an inappropriate value is set in certain characteristic.

Is it possible ?

Best regards.

Takeshi

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Dec 19, 2016 at 11:00 AM

    Hi Takeshi,

    Yes, it is possible. We would need a 'User-Defined function', here the link to the documentation:

    User-Defined Functions

    This function is linked to an ABAP one, that will make use of the MESSAGE statement. Here a simple trial of how it should look like:

    The code is simply checking the value of characteristic 'TEST_1' and, if it is above 100, it will generate a warning, like this:

    Instead of a pop-up, by changing the message type to 'W', the message can appear in the screen bottom:

    I do hope this could be of aome help; feel free to ask me in case further details are needed.

    Thank you and best regards,

    Flavio

    Add comment
    10|10000 characters needed characters exceeded

    • Hi, Flavio.

      Would it be possible to elaborate what is required after creating a function module ?

      I created the same function module as your example, but I could not find what kind of object to match with.

      It might be functions and object dependence editor according to SAP Help portal.

      Is my recognition right ?

      I would appreciate if you kindly give me some advice.

      Best regards.

      Takeshi

  • Dec 20, 2016 at 07:38 AM

    Hi Takeshi,

    Yes, you are perfectly right, we need an object dependency (a procedure) to consume the user defined function.

    In my simple example above, I've used the following:

    • user defined function (CU67):


      It has the characteristic we want to check as input parameter, and a dummy characteristic as returning parameter (we don't actually use it in our process, but it must be part of the function interface; it is simply a flag, here).
      In the header, we refer to the ABAP fuction:

    • Object dependency: a procedure

      with the following code, consuming the CU67 function above:

    • The above dependency is then inserted in the configuration profile, so that it will be processed during configuration.

    Hope this is helpin in clarifyng the topic. If you need further info, just let me know.

    Thank you and best regards,

    Flavio

    Add comment
    10|10000 characters needed characters exceeded

    • Hi, Flavio.

      Thank you for your quick reply.

      I'm glad to tell you my attempt to implement a warning message in the function of variant configuration was achieved successfully.

      I owe everything to you.

      I greatly appreciate your taking the time and detailed explanation.

      Best regards.

      Takeshi

  • Dec 19, 2016 at 07:52 AM

    Takeshi,

    This is possible via development. You can write a function (SE37) which works according to your logic, and then assign this function yo your characteristic.

    Add comment
    10|10000 characters needed characters exceeded

    • Hi, Kıvanç.

      Thank you for your quick reply.

      It appears to be impossible to make warning message pop up with standard functions but I can understand it is possible to achieve it with SE37.

      I would attempt to implement that.

      Thank you for your helpful answer.

      Best regards.

      Takeshi