Excel to Access using ADO

  • Thread starter Thread starter Quartz
  • Start date Start date
Q

Quartz

Please help if possible.

I would supply what I have so far, but it is really
convoluted garbage.

I am using ADO 2.5 in VBA from Excel XP with Windows 2000.

I have loaded an array with data from a spreadsheet.

Now, I need to copy it into a recordset (I guess) to
upload into an Access database (table exists and all
fields match).

I have seen many examples, but none seem to work. Can
someone supply me with example code on how to do this
please, please, please?

Your example code is most valuable thing I could get.
Thanks in advance.
 
Hi Keith,
I tried it too and it worked, I will certainly use it for my database
Thank you,
Annelie:)
 
Little Problem with my macro. Until now a ran a macro which sorted an
prepared the data to be imported to access. In the end range selectio
looked like this:
Range("A2").Select
Range(Selection, Selection.End(xlToRight)).Select
Range(Selection, Selection.End(xlDown)).Select
using end right, end down, because the data is not always the same
Actually the columns are always the same, but the rows are not..

How do I translate that to your macro?
Thanks in advance.
Annelie
 
Off the top of my head I would use a for each loop and go thru all th
cells that are selected and do some type of if statement to decide i
they should be added into the database. Hope that helps.

Keith
www.kjtfs.com
 
Back
Top