You said you found the library in the reference list. Did you click to check the
box next to it?
In the editor, before running the macro, delete the line "Dim oXL As
Excel.Application" and then start typing it in by hand. When you type the 'Ex'
in Excel, you should see 'Excel' selected in the popup list. Does that happen?
When you get to the '.Ap' part, does it suggest 'Application'?