06-30-2015 4:23 PM
Hi experts,
My code is as below.
*data declaration
types : begin of ty_final.
include structure zcla_star.
field-symbols : <fs_final> type ty_final
ls_cla type zcla_star,.
*Logic
clear lv_betrw.
lv_betrw = ls_cla-tax_amt.
if lv_betrw is not initial.
<fs_final> = ls_cla.-------------------------> runtime error
<fs_final>-amt_type = 'T'.
append <fs_final> to lt_final.
endif.
This error may occur if
- You address a typed field symbol before it has been set with
ASSIGN
- You address a field symbol that pointed to the line of an
internal table that was deleted
- You address a field symbol that was previously reset using
UNASSIGN or that pointed to a local field that no
longer exists
- You address a global function interface, although the
respective function module is not active - that is, is
not in the list of active calls. The list of active calls
can be taken from this short dump.
can you please let me know the reaason..?
thanks in advance
regards
niru
06-30-2015 4:29 PM
HI,
field symbol we have to assign otherwise it will return the short dump to avoid you have to write the code.
without assign we can't use them.
if <fs_final> is not assingned.
exit.
06-30-2015 4:29 PM
06-30-2015 4:36 PM
Hi..
Use Assign statement as like below. Else Field not assigned dump will throw.
ASSIGN ls_cla to <fs_final>
Regards
Rajkumar Narasimman
06-30-2015 4:49 PM
Hi NK,
<fs_final> = ls_cla.
<fs_final>-amt_type = 'T'.
Replace it with
assign ls_cla to <fs_final>.
assign 'T' to <fs_final>-amt_type.
Regards,
Raju