Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report from data generated in a procedure?

Status
Not open for further replies.

solun

Programmer
Apr 1, 1999
55
I've got a VBA event procedure that evaluates a bunch of data from multiple tables (over 100 fields with lots of conditionals, dates, etc.) and I want to send the results to a report.

Obviously, I need the "DoCmd.OpenReport" but how do I tell the report what to display? In my testing I'm just using debug.print statements to make sure the code is evaluting correctly - but those results are what I need my users to get from the report.

I hope the question makes sense to somebody!

Thanks!

Heidi


Heidi I. Jones
Ridgerunner Consulting
Questions Answered. Problems Solved.
 
How about:

-- Create a Results table to store the results of the VBA
-- In the VBA event procedure:

1. Add a SQL statement to delete any existing records in the 'results table'

2. Have your code next, as before

3. Post your VBA results to a new record in the Results table

4. Run a pre-written query or report to list these results



Bob Stubbs
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top