12-09-2009 7:36 PM
Hi.
I have applied extended verify code to my program. Into Obsolete Sentences, show me a sentence as obsolete:
form recupera_concepto tables it_in_par structure itcsy
it_out_par structure itcsy.
Within classes and interfaces, you can only use "TYPE" to refer to ABAP Dictionary
types, not "LIKE" or "STRUCTURE".
If I modify my code like this:
form recupera_concepto tables it_in_par type standar table itcsy
it_out_par type standar table itcsy.
Show me an error: "itcsy" has already been declared.
What can I do to solve this problem?. If I use first code, program works fine, but exist an error with extended verify code.
Any suggestion will be welcome.
Thanks a lot, regards.
12-09-2009 7:50 PM
You can declare as a type table, that will clear the error. But you could also put "#EC next to the statement, and that will hide the error.
TYPES: t_itcsy TYPE itcsy.
TYPES: tt_itcsy TYPE STANDARD TABLE OF t_itcsy.
FORM recupera_concepto TABLES it_in_par TYPE tt_itcsy
it_out_par TYPE tt_itcsy.
ENDFORM. "recupera_concepto
Regards,
Rich Heilman
12-09-2009 7:50 PM
You can declare as a type table, that will clear the error. But you could also put "#EC next to the statement, and that will hide the error.
TYPES: t_itcsy TYPE itcsy.
TYPES: tt_itcsy TYPE STANDARD TABLE OF t_itcsy.
FORM recupera_concepto TABLES it_in_par TYPE tt_itcsy
it_out_par TYPE tt_itcsy.
ENDFORM. "recupera_concepto
Regards,
Rich Heilman
12-09-2009 7:51 PM
12-09-2009 7:59 PM
Hi Jorge.
The problem is on TABLES alternative of command FORM. You can still use this form. If you want you can try the following:
FORM routine USING it_table_in TYPE TABLE.
*- here you define a wa of the type of it_table
DATA: wa_line TYPE ty_table.
...
*- here you process internal table as usual
LOOP AT it_table_in INTO wa_line.
...
ENDLOOP.
...
ENDFORM.
Do not forget close your posts.
Regards.
Rafael Rojas.
12-09-2009 8:07 PM