P
Pozzo
I posted a couple of days ago and didn't get any answers. Anyway, th
problem has evolved somewhat since so I'm re-posting in the hope tha
somebody can help this time.
I have a query on an Access database which gives me product details an
is fairly large, approx. 16,000 records. I am working on a spreadshee
to forecast sales and would like to pull in information based on th
product code entered by the user. My idea initially was simply t
create a query that imported this data into a sheet and reference th
appropriate cells from the forecasting sheet. I quickly realised tha
all these references and lookups both made the workbook too slow an
physically too large. It seems obvious that the query needs to b
dynamically generated to only return the data relating to the produc
codes entered on the sheet. After perusing some of the posts here,
tried the Sql.request workbook function but unfortunately this seems t
execute the query in each cell rather than returning data to a range o
cells, and additionally refreshes every time the user moves cell (
need to keep automatic updates on).
Would it be possible using VBA to run the query, keep the returned dat
in an array, and then copy the data to the appropriate cell
programatically? If not, can anybody suggest a better solution.
edit: I am using Excel 2000, but the solution needs to work for '97
Any help is greatly appreciated.
Lee
problem has evolved somewhat since so I'm re-posting in the hope tha
somebody can help this time.
I have a query on an Access database which gives me product details an
is fairly large, approx. 16,000 records. I am working on a spreadshee
to forecast sales and would like to pull in information based on th
product code entered by the user. My idea initially was simply t
create a query that imported this data into a sheet and reference th
appropriate cells from the forecasting sheet. I quickly realised tha
all these references and lookups both made the workbook too slow an
physically too large. It seems obvious that the query needs to b
dynamically generated to only return the data relating to the produc
codes entered on the sheet. After perusing some of the posts here,
tried the Sql.request workbook function but unfortunately this seems t
execute the query in each cell rather than returning data to a range o
cells, and additionally refreshes every time the user moves cell (
need to keep automatic updates on).
Would it be possible using VBA to run the query, keep the returned dat
in an array, and then copy the data to the appropriate cell
programatically? If not, can anybody suggest a better solution.
edit: I am using Excel 2000, but the solution needs to work for '97
Any help is greatly appreciated.
Lee