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

Problem with tabstrip 'Save' button

When I click on the 'Save' button for my tabstrip which has 3 tabs, the error is shown for what i want for the first tab as shown at this link:

http://img185.imageshack.us/img185/7290/screen1eg6.png

But when I look at my second and third tabs, the screen's input field is disabled when it is suppose to be enabled for the user to key in. The screen as show here:

http://img185.imageshack.us/img185/6615/screen2ns8.png

Line: -


My codes as below:

MODULE USER_COMMAND_9000 INPUT. Screen 9000 is the that contain the tabstrip

IF SY-UCOMM = 'BACK'.

LEAVE PROGRAM.

ELSEIF SY-UCOMM = 'EXIT'.

LEAVE PROGRAM.

ELSEIF SY-UCOMM = 'SAVE'.

IF IO_NAME IS INITIAL.

MESSAGE E004(ZMSG02).

CLEAR SY-UCOMM.

ELSEIF IO_AGE IS INITIAL.

MESSAGE E005(ZMSG02).

CLEAR SY-UCOMM.

ELSEIF IO_GENDER IS INITIAL.

MESSAGE E006(ZMSG02).

CLEAR SY-UCOMM.

ELSE.

PERFORM INSERT_TABLE.

ENDIF.

ENDIF.

ENDMODULE. "USER_COMMAND_9000 INPUT

MODULE USER_COMMAND_9001 INPUT. Screen 9001 contains the subscreen for first tab

CASE SY-UCOMM.

WHEN 'SAVE'.

IF IO_NAME IS INITIAL.

MESSAGE E004(ZMSG02).

PERFORM INSERT_TABLE.

ENDIF.

ENDCASE.

ENDMODULE. "USER_COMMAND_9000 INPUT

MODULE USER_COMMAND_9002 INPUT. Screen 9002 contains the subscreen for second tab

CASE SY-UCOMM.

WHEN 'SAVE'.

IF IO_AGE IS INITIAL.

MESSAGE E004(ZMSG02).

ELSE.

PERFORM INSERT_TABLE.

ENDIF.

ENDCASE.

ENDMODULE.

MODULE USER_COMMAND_9003 INPUT. Screen 9003 contains the subscreen for third tab

CASE SY-UCOMM.

WHEN 'SAVE'.

IF IO_GENDER IS INITIAL.

MESSAGE E004(ZMSG02).

ELSE.

PERFORM INSERT_TABLE.

ENDIF.

ENDCASE.

ENDMODULE.

Line: -


Please tell me what is wrong with my codes? Please type out the codes to let me understand. I will reward all useful answers

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

8 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 06:07 AM

    Hai Juzme,

    For your First Screen : Your did your code like if IO_NAME is initial then you are showing error message. so the output is showing like that only.

    For second Screen : I think problem in screen painter attributes, Once you check the input field and output field Check boxes.

    Regards,

    Nagaraju.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 06:29 AM

    I tried to change the Input attributes and still the same outcome. Any other solutions?

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 06:35 AM

    Hi,

    Try this code in the tabstrip screens:

    loop at screen.

    if sy-dynnr = 'your screen no'.

    if screen-name = <your io field name>.

    screen-input = 1.

    modify screen.

    endif.

    endif.

    modify screen.

    endloop.

    Hope this helps. Also check whether you have the active tab as youre required one itself.

    regards,

    Renjith Michael.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 06:43 AM

    Where am I suppose to put the code you mentioned? Is it at my screen 9000 codes?

    Please tell me exactly where to put exactly. Here is my screen 9000 codes

    -


    PROCESS BEFORE OUTPUT.

    *&SPWIZARD: PBO FLOW LOGIC FOR TABSTRIP 'TABNAME2'

    MODULE TABNAME2_ACTIVE_TAB_SET.

    CALL SUBSCREEN:

    9001_SCA INCLUDING G_TABNAME2-PROG '9001',

    9002_SCA INCLUDING G_TABNAME2-PROG '9002',

    9003_SCA INCLUDING G_TABNAME2-PROG '9003'.

    MODULE STATUS_9000.

    *

    PROCESS AFTER INPUT.

    *&SPWIZARD: PAI FLOW LOGIC FOR TABSTRIP 'TABNAME2'

    CALL SUBSCREEN:

    9001_SCA,

    9002_SCA,

    9003_SCA.

    MODULE TABNAME2_ACTIVE_TAB_GET.

    MODULE USER_COMMAND_9000.

    -


    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 07:02 AM

    I got this problem when I try to put the code to my screen 9001.

    http://img267.imageshack.us/img267/7522/erroryo4.png

    How am I suppose to put the code?

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi,

      It is due to the reason that you cannot directly code thatin the PBOitself.

      Instead, in the place you have added the code create a module, say,

      PROCESS BEFORE OUTPUT.

      module input_data.

      double click on the modulename and create it.

      Inside the module wirte the same code you wrote earlier and activate.

      Regards,

      Renjith Michael.

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 07:27 AM

    The problem still remains even after i did that.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi,

      Just try changing the Erroe Messages to Status Messages like:

      IF IO_NAME IS INITIAL.

      MESSAGE E004(ZMSG02).

      CLEAR SY-UCOMM.

      ELSEIF IO_AGE IS INITIAL.

      MESSAGE E005(ZMSG02).

      CLEAR SY-UCOMM.

      ELSEIF IO_GENDER IS INITIAL.

      MESSAGE E006(ZMSG02).

      to

      IF IO_NAME IS INITIAL.

      MESSAGE S004(ZMSG02).

      CLEAR SY-UCOMM.

      ELSEIF IO_AGE IS INITIAL.

      MESSAGE S005(ZMSG02).

      CLEAR SY-UCOMM.

      ELSEIF IO_GENDER IS INITIAL.

      MESSAGE S006(ZMSG02).

      Change any other error messages also to Status messages.

      just to see if this causes the error. If so we will find an alternate solution.

      Regards,

      Renjith Michael.

      Edited by: Renjith Michael on Jan 10, 2008 1:20 PM

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 08:49 AM

    I will still need to use the E error messages. Any other solutions?

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi,

      You can use the Error messages. but in some cases the error messages can cause this kind of problems. So you can check if this is the cause and later you can revert to the original. or judt try by setting defult values to the input fields.

      Regards,

      Renjith Michael.

      Edited by: Renjith Michael on Jan 10, 2008 2:34 PM

  • author's profile photo Former Member
    Former Member
    Posted on Jan 10, 2008 at 09:06 AM

    then how do i check this problem?

    Add a comment
    10|10000 characters needed characters exceeded

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.