Skip to Content
author's profile photo Former Member
Former Member

selection screen issue

Hi,

in alv report while giving t-code the default values are shown,

dmrdate 02.10.2014 to 06.10.2014

noof days 0 to 5

based on no of days dmrr date is calculated 0 means current date and 5 means current date - 5 days.

so while giving t-code it automatically takes the value,but now the user erase the dmrr date and give number of days as sometnkng

let us assume 0 to 1 means. 05.10.2014 to 06.10.2014.

so while giving no of days as 0 to 1 and press enter means it takes 05.10.2014 to 06.10.2014. in dmrr date.

but i don want to show this date,the field should be empty,but the value run in background processing(select query must contains dmrr date)

and my code is....any one help how to clear dmrr date value in selection screen.

at selection screen.

if so_dmdat[] is initial and so_noday-high is not initial.

so_dmdat-low = sy-datum - so_noday-high. .

so_dmdat-high = sy-datum .

so_dmdat-option = 'BT'.

so_dmdat-sign = 'I'.

APPEND so_dmdat.


if i give at selection screen output means so_dmdat value is cleared...

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Posted on Oct 06, 2014 at 08:47 AM

    sorry, but i'm missing your requirement: you want to overwrite ALWAYS SO_DMDAT values or just when it's initial and without the user recognize it?

    SO_DMDAT should not be obligatory

    To clear ALWAYS values in SO_DMDAT

    AT SELECTION-SCREEN OUTPUT

    clear: so_dmdat, so_dmdat[]

    To force value without user recognize it.

    START-OF-SELECTION

    if so_dmdat[] is initial and so_noday-high is not initial.

    so_dmdat-low = sy-datum - so_noday-high. .

    so_dmdat-high = sy-datum .

    so_dmdat-option = 'BT'.

    so_dmdat-sign = 'I'.

    APPEND so_dmdat.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 06, 2014 at 08:51 AM

    Hi Christina,

    Do you want to hide the SO_DMDAT from selection screen, but not really discard it from selection screen? If so, then you can add "NO-DISPLAY" at your select-options.

    Ex : SO_DMDAT FOR SY-DATUM NO-DISPLAY.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      I see.. then you could use MODIFY SCREEN as your solution.

      Ex : SELECT-OPTIONS : SO_DMDAT FOR SY-DATUM MODIF ID 'ABC'.

      then AT SELECTION-SCREEN OUTPUT add your logic to hide or not :

      LOOP AT SCREEN.

      IF SCREEN-GROUP1 EQ 'ABC'.

      IF {add your logic here whenever you want to hide or show}.

      SCREEN-INVISIBLE = 1. "HIDE

      ELSE.

      SCREEN-INVISIBLE = 0. "DISPLAY

      ENDIF.

      MODIFY SCREEN.

      ENDIF.

      ENDLOOP.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.