Application Development 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: 

module pool save icon

Former Member
0 Kudos

Hi all,

i have a module pool program where it's used for creating,modifing a business object. i have a save icon in application tool bar to save the code .

but the problem here is in the modification part where i have a table control and the data which is modified is being saved correctly but i have another icon(not in app tool bar) where it's used to delete a particular row in the table control. and when iam saving it, the row is not being deleted from the database table .can anyone help me in this issue.

PAI

MODULE USER_COMMAND_0110 INPUT.

case ok_code.

when 'DELCON'.

perform delete_condition_row.

refresh control 'TAB_COND' from screen '1004'.

endcase.

ENDMODULE. " USER_COMMAND_0110 INPUT

FORM delete_join_row .

DATA L_SELLINE LIKE SY-STEPL.

GET CURSOR LINE L_SELLINE.

DELETE g_TAB_join_itab INDEX L_SELLINE.

ENDFORM. " delete_join_row

MODULE USER_COMMAND_1000 INPUT.

case ok_code.

when 'save'.

data zgnx_cond_tab type table of zgnx_condition.

data zgnx_cond_wa type zgnx_condition.

refresh: zgnx_cond_tab.

clear: zgnx_cond_wa.

loop at g_TAB_COND_itab

into g_TAB_COND_wa.

move-corresponding g_TAB_COND_wa to zgnx_cond_wa.

zgnx_cond_wa-obj_name = SCR1000-OBJ_NAME.

append zgnx_cond_wa to zgnx_cond_tab.

endloop.

MODIFY zgnx_condition from table zgnx_cond_tab.

ENDMODULE.

This is the code that i have used.

1 ACCEPTED SOLUTION

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

You have not coded to delete from the db table, only from the internal table.



FORM delete_join_row .
DATA L_SELLINE LIKE SY-STEPL.
GET CURSOR LINE L_SELLINE.
<b>DELETE g_TAB_join_itab INDEX L_SELLINE.</b>
ENDFORM. "


Regards,

RIch Heilman

4 REPLIES 4

Former Member
0 Kudos

Hi,

What is screen 1000 and screen 0110. R u calling subscreens, if yes address me the screen sequence and the logic..

Rgds

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

You have not coded to delete from the db table, only from the internal table.



FORM delete_join_row .
DATA L_SELLINE LIKE SY-STEPL.
GET CURSOR LINE L_SELLINE.
<b>DELETE g_TAB_join_itab INDEX L_SELLINE.</b>
ENDFORM. "


Regards,

RIch Heilman

0 Kudos

Hi,

can anybody give me exact idea about module pool and d/b table creation with navigation by taking a simple example like emp table?

Former Member
0 Kudos

hi Rich,

I know that i didn't code for updating the internal table into the database.can u suggest me how can i code it.

Thanks