Access 2007 and SQL Server 2008 R2.
I have a query that runs fine. I would like to pass the results to VBA variables. Then I will write an update query in VB and update the Property table and then run a requery to update the screen.
SELECT dbo_TownshipLookup.TownshipName, dbo_TownshipLookup.TownshipNO,dbo_CountyLookup.Cou ntyName, dbo_TriCycleLookup.CycleName, dbo_VolumeLookup.Volume
FROM ((dbo_TownshipLookup INNER JOIN dbo_TriCycleLookup ONdbo_TownshipLookup.TricountyID = dbo_TriCycleLookup.TricountyID) INNER JOINdbo_CountyLookup ON dbo_TriCycleLookup.CountyID = dbo_CountyLookup.CountyID)INNER JOIN dbo_VolumeLookup ON dbo_TownshipLookup.TownshipName =dbo_VolumeLookup.Township;
The query runs fine and returns the proper results. What I don't know is how to pass the results of the query to the VBA module. I am ok with the syntax and variables involved, I just don't know how to create the methodology to capture the query results and place them into appropriate variables. I think I create a record set for the results but I'm not really sure.
Thanks
Phred