The first line of my subroutine in Excel VBA module is the declaration of the ADODB.Connection:
And it stops there with an error message:
User-defined type not defined
Strangely enough, I have a very similar Sub in another Excel file which start with exactly the same declaration and it works. Any help is greatly appreciated!!! ---
---
Code:
Dim con As New ADODB.Connection
And it stops there with an error message:
User-defined type not defined
Strangely enough, I have a very similar Sub in another Excel file which start with exactly the same declaration and it works. Any help is greatly appreciated!!! ---
---