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

module_pool(messages)

hai all,

in my layout one table control with two colums.

iam giving entries like this.

1 10000

2 20000

30000 this entry not accept, at that time raise message error not fill first column.

give me solution.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

4 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Mar 30, 2009 at 06:06 AM

    See the following report

    DEMO_DYNPRO_TABLE_CONTROL_2

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Mar 30, 2009 at 06:06 AM
    PAI.
    Loop at ITAB.
    Module table_ftest.
    ENDLOOP.
    
    Module table_ftest.
    IF itab-field is initial.
    Message 'XXX' type 'W'.
    Endif.
    ENDMODULE.

    regards,

    Gurpreet

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Mar 30, 2009 at 06:10 AM

    Hi,

    Refer:-

    it_zekpo is my internal table w/o header line,

    wa_zekpo is work area.

    Name of input/output fields on screen are:-

    wa_zekpo-field1,

    wa_zekpo-field2, and so on...

    At screen flow-logic

    PROCESS BEFORE OUTPUT.
    *  MODULE status_8003.
     
      LOOP WITH CONTROL po_tb.
        MODULE read_data.
      ENDLOOP.
     
    PROCESS AFTER INPUT.
    *  MODULE user_command_8003.
     
      LOOP WITH CONTROL po_tb.
        MODULE modify_data.
      ENDLOOP.
    

    In PBO

    *&---------------------------------------------------------------------*
    *&      Module  READ_DATA  OUTPUT
    *&---------------------------------------------------------------------*
    MODULE read_data OUTPUT.
      READ TABLE it_zekpo INTO wa_zekpo INDEX po_tb-current_line. "po_tb is table control name
     
      data : line_count type i.
     
      describe it_zekpo
      lines line_count.
     
      po_tb-lines = line_count + 10.
      "to increase the number of lines in table control dynamically
    ENDMODULE.                 " READ_DATA  OUTPUT
    

    In PAI

    *&---------------------------------------------------------------------*
    *&      Module  MODIFY_DATA  INPUT
    *&---------------------------------------------------------------------*
    MODULE MODIFY_DATA INPUT.
    
      IF wa-zekpo-ebeln is initial. "<--if first field is empty
        MESSAGE 'Fill first column entries' TYPE 'E'. "<--raise error message
      ELSE. "<--else modify internal table from table control
        MODIFY IT_ZEKPO FROM WA_ZEKPO INDEX po_tb-currentline.
        "this will modify the contents of existing line into internal table
      ENDIF.
    ENDMODULE.                 " MODIFY_DATA  INPUT
    

    Hope this helps you.

    Regards,

    Tarun

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Mar 30, 2009 at 06:13 AM

    thanks.

    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.