Skip to Content
0
Former Member
May 30, 2008 at 09:44 PM

Update Termination in VA01 - userexit_move_field_to_vbkd

315 Views

Hi,

I am trying to modify a field KONDA in VBKD structure in USEREXIT_MOVE_FIELD_TO_VBKD.

But after creation, when I go back, it is giving a message 'Update Termination' with my user name

This is the logic I am writing in this exit

loop at xvbkd into ls_xvbkd.

lv_tabix = sy-tabix.

ls_item1 = ls_xvbkd.

ls_item1-konda = gc_eff_prcgrp.

vbkd-konda = gc_eff_prcgrp.

IF ls_xvbkd-updkz EQ space AND t180-trtyp EQ charv.

ls_yvbkd = ls_xvbkd.

append ls_yvbkd to yvbkd.

ls_xvbkd-updkz = charu.

upd_vbkd = charu.

endif.

move-corresponding ls_item1 to ls_xvbkd.

MODIFY xvbkd FROM ls_xvbkd INDEX lv_tabix.

endloop.

can someone suggest me if I am making any mistake on this?

When I check in debug more, it is creating one more entry in XVBKD structure with same values.

This is the reason, it is giving me an duplicate record exception.

can someone suggest me how to resolve this?

Thanks in advance.

Shylesh