Calling a result from another sub procedure

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a report that generates a result in a private sub. I would like to
utilize that result in another report's private sub. How do I call just the
result from the other report?

Thanks in advance.
 
declare a Public variable (in a general module)

When the result is 1st generated, store the value in the variable.

When the 2nd report runs, have it read the "most recently generated" value.
Of course, if the 1st report hasn't been run, the 2nd report will be reading
garbage.

Otherwise, make the function public and place it in a general module and
call it from both reports.
That way a "good" value would be available to both reports regardless of the
order in which they are run.

HTH,
 
Back
Top