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

Output only screen field problem - module pool

I want to display site descriptoin behind the site number and the article description behind the article number after I input the site /article number and press ENTER.

That is:

Site : 9999 Site Name

Article: 1111 Aritle Description

I create a view contains site/site name/article/article description, and make site and article are input/output screen fields, but site name and article description are output only screen fields.

When I execute the program, i input the site and article then Enter, the program execute but the site name/article are not shown

What is the problem?! the view or screen fields?

Thanks in Advance

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

4 Answers

  • Posted on Jan 11, 2007 at 03:19 AM

    Keep the <b>SAME Variable name</b> on report & Screen field. It will solve your problem.

    Raja T

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 11, 2007 at 03:34 AM

    Leo,

    design the like below.

    1.Text field & Label field

    2.Declare the same names(names of the above fields) of the fields in ABAP editor

    3.In PAI take the input values and pass the values to concerned fields.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jan 11, 2007 at 03:48 AM

    Hi Leo,

    Check out this code. This is working fine.

    *-- Data Declarations :

    DATA : i_dynfields TYPE STANDARD TABLE OF dynpread WITH HEADER LINE.

    DATA: ws_repid TYPE d020s-prog,

    ws_num TYPE d020s-dnum,

    cvp_desc LIKE zcvpconfig-cvp_desc, " Same as screen name

    cvp_no LIKE zcvpconfig-cvp_num. "Same as screen name

    PROCESS AFTER INPUT.

    MODULE user_command_0100.

        • input check for field cvp number

        <b>FIELD : cvp_no.

        MODULE show_cv_desc</b>.

        The module definition for show_cv_desc as follows :

        &----


        *& Module show_cv_desc INPUT

        &----


        • text

        ----


        MODULE show_cv_desc INPUT.

        ws_repid = sy-cprog.

        ws_num = '1000'.

        i_dynfields-fieldname = 'CVP_NO'.

        APPEND i_dynfields.

        CALL FUNCTION 'DYNP_VALUES_READ'

        EXPORTING

        dyname = ws_repid

        dynumb = ws_num

        TABLES

        dynpfields = i_dynfields

        EXCEPTIONS

        invalid_abapworkarea = 1

        invalid_dynprofield = 2

        invalid_dynproname = 3

        invalid_dynpronummer = 4

        invalid_request = 5

        no_fielddescription = 6

        invalid_parameter = 7

        undefind_error = 8

        double_conversion = 9

        stepl_not_found = 10

        OTHERS = 11.

        IF sy-subrc EQ 0.

        READ TABLE i_dynfields WITH KEY fieldname = 'CVP_NO'.

        IF sy-subrc EQ 0.

        cvp_no = i_dynfields-fieldvalue.

        ENDIF.

        ENDIF.

        <b>loop at screen.

        if screen-name = 'CVP_DESC'.

        if cvp_no = '0012'.

        cvp_desc = 'SATYA'.

        elseif cvp_no = '0014'.

        cvp_desc = 'PRIYA'.

        endif.

        modify screen.

        endif.

        endloop.</b>ENDMODULE. " show_cv_desc INPUT

        Hope this will help u.

        Add a comment
        10|10000 characters needed characters exceeded

      • author's profile photo Former Member
        Former Member
        Posted on Jan 11, 2007 at 04:13 AM

        in enter fn code in PAI of the screen select the data from view.

        if you are trying to display in list in the second screen you have to use

        LEAVE TO LIST-PROCESSING.

        Addition:

        ... AND RETURN TO SCREEN scr.

        above command here you can use write statement and all other things like report.

        if it is not like so then check view contains any data or not.

        regards

        shiba dutta

        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.