Method of recordset objet...Compile error

S

Scott Tucker

The following code works just fine with Word 97 and ADO
2.1 to 2.6. However, with Word 97 and ADO 2.7 (i.e.
Windows XP) it won't even compile. I get a "Compile
error: invalid use of object," and it highlights Append.
Object Browser shows that ADODB 2.7 has a Fields class
and an Append method. Any ideas?

Dim rsTemp As New ADODB.Recordset
rsTemp.Fields.Append "AField", adBSTR

Thanks,
Scott
(e-mail address removed)
 
C

Chris Worth

Are you references okay (Tools -> References)? I have had
weird problems by having extras and gotten around then by
turning them all off and enabling them one-by-one.
 

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

Top