Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

PROBLEM IN MODULE POOL PROGRAMMING

Former Member
0 Likes
476

HI,

WHAT ARE STEPS INVOLVED IN MODULE POOL PROGRAMMING.

I WANT A I/O FIELD BASED ON THAT THE HEADER AND ITEM VALUES WILL BE DISPLAYED.

THE ITEM VALUES SHOULD BE IN A TABLE CONTROLS.

ONLY AFTER THE I/O FILED IS GIVEN AND PRESS ENTER THEN ONLY THE SCREEN SHOULD BECOME ACTIVE.

WHEN I AM DOING THIS I AM GETTING ERRORS.

CAN ANYONE TELL ME THE PROCEDURE FOR THE SAME.HELPUL IF A EXAMPLE I GIVEN.

3 REPLIES 3
Read only

Former Member
0 Likes
439

chk these demo programs , It would be better if u can post ur error

DEMO_DYNPRO_TABCONT_LOOP_AT

DEMO_DYNPRO_TABLE_CONTROL_1

DEMO_DYNPRO_TABLE_CONTROL_2

DEMO_DYNPRO_TABSTRIP_LOCAL

DEMO_DYNPRO_TABSTRIP_SERVER

Read only

Former Member
0 Likes
439

Hi,

refer ABAPDOCU transaction for sample programs

follow below pseudeo code for ur requirement

100 screen pai

when 'ENTER'.

if not l_field is initail.

leave to screen 200.

endif.

in 200 screen define table control

LOOP AT INT_ZBKTSTKREC_EDIT WITH CONTROL CTRL_1520 "Main loop

CURSOR CTRL_1520-CURRENT_LINE.

ENDLOOP.

MODULE STATUS_1520. "Screen Control

MODULE SET_CURSOR_1520.

************************************************************************

PROCESS AFTER INPUT.

  • Store internal table information inputted by the end user

LOOP AT NT_ZBKTSTKREC_EDIT. " CHAIN.

FIELD INT_ZBKTSTKREC_EDIT-RECONCILED.

FIELD: INT_ZBKTSTKREC_EDIT-KBBLUNREC,

INT_ZBKTSTKREC_EDIT-REASON_CD.

MODULE LINEIN_INT_ZBKTSTKREC_1520.

ENDCHAIN.

ENDLOOP.

  • Process User event

MODULE USER_COMMAND_1520_LAST.

  • Provide field drop downs on specified fields

PROCESS ON VALUE-REQUEST.

FIELD INT_ZBKTSTKREC_EDIT-REASON_CD

MODULE VALUES_REASON_CD.

Regards,

Amole

Read only

Former Member
0 Likes
439

hi Amit,

Check out the demo program

demo_dynpro_tabcont_loop,

demo_dynpro_tabcont_loop_at,

DEMO_DYNPRO_TABLE_CONTROL_1 and

DEMO_DYNPRO_TABLE_CONTROL_2.

Step by step.

1. Define a variable (s_field) and an internal table. Write select statement to fetch data from databese.

2. create a screen and define a i/o box(with same name s_field) and a button.

3. Click on table control wizard and drag and drop it on screen. Enter teh table name and other details.

activate teh code. The table control wizard will get all the code needed to display the field value in the table control.

4. In user_command module, write the code

  if ok_code = 'EEE'" function code of button.
    perform fetch_data.
  endif."or you can use case-endcase statement

Regards,

Richa