Application Development and Automation 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: 
Read only

Global variable

Former Member
0 Likes
460

Hi All,

i have define a global variable in top include as

g_okcode type sy-ucomm.

if ok_code = 'AUDIT'

g_okcode1 = ok_code then am calling the FM

CALL FUNCTION 'EDI_DOCUMENTS_LIST_ONE_SEGMENT'

TABLES

I_EDIDC = choose_edidc

*Here my requirement is to retain the values in the global variable in FM to check. <REMOVED BY MODERATOR>

Thanks in advance,

Padmasri.

Edited by: Alvaro Tejada Galindo on Feb 18, 2008 10:49 AM

1 REPLY 1
Read only

Former Member
0 Likes
415

Is that FM standard? I'm in 4.6C and we don't have it here.

If is not standard, just do the following in the code.


data ls_text(40).
field-symbols <fs> type sy-ucomm.

ls_text = 'NAME_OF_YOUR_PROGRAM(g_okcode)'.

assign (ls_text) to <fs>.

if sy-subrc = 0
if <fs> = 'whatever you want to validate'
...
endif.
endif.

Edited by: Ramiro Escamilla on Feb 18, 2008 5:44 PM

fixed not enough chars in ls_text