
Using ADO Recordset with Forms (ADO vs DAO)
Hello,
I have a situation where I have an Excel spreadsheet that contains a
list of records that I need to append to an Access Table (MS-Access
2000). I also need to display some of those records and manipulate
them within my MS-Access 2000 application.
I figured the easiest thing would be to create an ADO Recordset that
contains the MS-Excel records and then use it in my application as a
Recordset.
The first thing that I wanted to do was to display the records in a
subform / datasheet for the user to preview before commiting to the
import.
I setup my sub-form and everything looked fine until I tried to assign
the ADO Recordset to the form as in:
Me.Recordset = rs (ADO Recordset)
It gave me an error message about different Recordsets or something.
I have read here and there about problems with ADO and DAO but I don't
know too much about it. I don't normally use MS-Access. In the past
I have used either Delphi or VB and worked almost exclusively with
MS-SQL Server, lastely version 7.0 which uses ADO -- hence my working
with ADO so much.
I have never worked with DAO, only ADO before which as I understand it
is the newer technology and the way to go (although I have seen
remarks to the contrary). I find it quite confusing (and certainly a
little fustrating) as it seems that nothing is constant. I was under
the impression that Microsoft was making life easier by providing an
overall standard, but that doesn't seem to be the case??
Anyways -- my first question is: Can I import the Excel data into my
Access application using Recordsets? Either by using DAO to access
Excel or by using ADO Recordsets with forms?
Secondly -- can anyone give some pointers (or a pointer) to where I
can find more information about ADO vs DAO -- what one should use
when, why, and how?
I have already spent enough time in the past learning technologies
that quickly became extinct and although it is inevitable, I would
like to try and slow the process down somewhat!!
Thanks,
Hugh