I'm trying to run a routine from Excel that populates a spreadsheet by creating an ADODB connection to an Access database and opening an exsting query.
This query contains a couple of tables that are linked into the Access database from other databases.
When I run the routine I get the error message "Too few paramaters. Expected 1". Interestingly if I try to run the routine locally or against tables that aren't linked tables, then it works OK.
I've also tried DAO with the same result.
Anyone know if there are any problems with ADO or DAO connections when the tables being used are actually linked tables?
I know the above way of doing things isn't the best and it would be easier to produce the spreadsheet from the Access database, but it seems that thats the way they want things round here...
After I posted originally I went back and re-examined the query, and realised that there was a significant field missing. The query was composed of other queries, so the error was slightly hidden, but I should have spotted it.
I think part of the problem was that I was told to have a look at this, and that the problem was to do with the linked tables....should have examined everything myself from the start.