Globally declared variables from the program will not be available in the function module that is called. Function modules reside in a group and these groups are factually a report. As any report, global variables can be declared and when a function module from the group is called, it could set a value that will be available the next time the function module is called. Or even available for other function module calls (to the same function group).

When information needs to be available globally, storing data in the global memory of a function group is an option. The information will be available to the function modules in the group, so you could have a module work with the selection results from another module. The Object Oriented paradigm holds much better, stronger and more readable means of global memory management.

With object oriented programming, a much better alternative to memory management in function groups is available. Much much better.