cancel
Showing results for 
Search instead for 
Did you mean: 

Field Symbol is not defined as a local field symbol

Former Member
0 Kudos

I m modifiying the smartform which was develped in 4.6 by copying in ECC version, I have the below error in one of the program line node which was created under the main window., Please sugest me

FIELD-SYMBOLS: <ls_table>.

ASSIGN LOCAL COPY OF INITIAL LINE OF <it_pos> TO <ls_table>.

error: Field Symbol is not defined as a local field symbol

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Try below code:-

DATA g_dobj TYPE i.

DATA dref TYPE REF TO data.

FIELD-SYMBOLS <l_dobj> TYPE ANY.

CREATE DATA dref LIKE g_dobj.

ASSIGN dref->* TO <l_dobj>.

Former Member
0 Kudos

when i use the above code i am geeting error " create data in not accessable."

kindly suggest.

Former Member
0 Kudos

when i use the above code i am geeting error " create data in not accessable."

kindly suggest.

asik_shameem
Active Contributor
0 Kudos
FIELD-SYMBOLS: <ls_table>. " Should be declared inside a subroutine.

Actually ASSIGN LOCAL COPY statement is obsolete.

Instead you can use CREATE DATA statement.