connect to MS SQL

  • Thread starter Thread starter mk
  • Start date Start date
The ado.ocx is an ActiveX control that needs to be licensed to be used in a
project and you , apparently, do not have that license. You should still be
able to use ADO in VBA if you add a reference to "Microsoft ActiveX Data
Objects Library" (this should be the file "msadonn.dll" where nn is the
version number). But even easier is to let MSQuery do the work for you: from
the Data menu choose "Import External Data..." and "New Database Query..."
Then you need to specify your data source (SQL Server) and design a query in
MSQuery to get the data you want (MSQuery acts a little like MS Access).
Once you have your data set you "Return Data to Microsoft Excel" (File menu
in MSQuery) and that will dump it onto a worksheet - from there you can use
formulas and lookups to manipulate the data. For info refer to Help file and
lookup "Importing Data."
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top