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: 

Retrieve value contained inside a workarea: its desc is in a text variable

Former Member
0 Kudos

Hi All,

I have a scenario where in my work area description is stored inside a text variable, say,

v_text = 'wa_temp-age'. ( Actually wa_temp-age contains value 20)

The content of v_text is dynamic.

Now I want to populate that value in another variable.

i.e v_age = (value of content stored v_text).

1 ACCEPTED SOLUTION

kesavadas_thekkillath
Active Contributor
0 Kudos

DATA:wa_text TYPE char20,
     v_text TYPE char20,
     v_age TYPE char20.

FIELD-SYMBOLS:<fs> TYPE ANY.

wa_text = '12345'.
v_text = 'WA_TEXT'.
ASSIGN (v_text) TO <fs>.
v_age = <fs>.
WRITE v_age.
3 REPLIES 3

Former Member
0 Kudos

Hi

You can do it by using field symbols. If you just copy a part of your code then it would be good to explain.

Best Regards,

Nikhil Patil

kesavadas_thekkillath
Active Contributor
0 Kudos

DATA:wa_text TYPE char20,
     v_text TYPE char20,
     v_age TYPE char20.

FIELD-SYMBOLS:<fs> TYPE ANY.

wa_text = '12345'.
v_text = 'WA_TEXT'.
ASSIGN (v_text) TO <fs>.
v_age = <fs>.
WRITE v_age.

0 Kudos

Hi,

Thanks a lot. It worked.

Awarded points.