Hi Joe,
The code from the MVP site is demonstration code only - it's not intended to be thought of as a tailor-made solution.
Presumably the error you referred to occurs on the line:
Set rs = db.OpenRecordset("SELECT * FROM 'PEdatabase'")
You need to use an SQL query that matches your workbook structure and what you're trying to extract.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
|