I've got a project where I'm reading data from an Excel worksheet and saving it in Access tables (not a direct import--see this question if you're interested). My current problem is that any time I run my "import" and then try to open the workbook in Excel, it's "locked for editing" unless/until I close Access. I don't think this should be the case. My process is
- Open the workbook with Automation.
- Build a collection of sheet names.
- Release the Automation objects.
- If there's more than one sheet, get user input on which to process.
- Open an ADO recordset on a specific range & read some data.
- Release the recordset & connection.
- Open an ADO recordset on a different specific range & read a bunch o' data.
- Release the recordset & connection.
- Close the controling form.
Steps 1 - 4 and 9 live in the form file, the remainder in a module.
Am I missing something? I think I've released all the references to the workbook....