Hi,
You cannot close connection because your recordset is opened against it. To
solve this issue you could open recordset on a client side, then disconnect
it from the connection setting ActiveConnection of it to Nothing. After that
you still have an opened recordset, but now you could close connection.

Signature
Val Mazur
Microsoft MVP
http://xport.mvps.org
>I created a function whose only job is to open a recordset, passing various
> parameters to it that it might need to know. The idea was to then pass
[quoted text clipped - 10 lines]
> way
> but maybe not.
smk23 - 24 May 2005 02:12 GMT
Val: I am using VBA in MS Access 2003. Does that support a disconnected
recordset? I know that .Net does. But now it's complaining that the
connection is closed. I changed the cursor location to client.

Signature
sam
> Hi,
>
[quoted text clipped - 17 lines]
> > way
> > but maybe not.
Val Mazur (MVP) - 25 May 2005 01:45 GMT
Hi,
Yes, it supports disconnected recordsets as well. What is your code? Could
you post it here? Where it complains that connection is closed?

Signature
Val Mazur
Microsoft MVP
http://xport.mvps.org
> Val: I am using VBA in MS Access 2003. Does that support a disconnected
> recordset? I know that .Net does. But now it's complaining that the
[quoted text clipped - 28 lines]
>> > way
>> > but maybe not.
smk23 - 28 May 2005 14:16 GMT
Val, thanks. Problem is that I am learning from someone else's code and I
don't know what I'm doing. I'm going to get a book (Bill Vaughn's?) and get a
better grasp of the topic. I couldn't pinpoint the issue right now.

Signature
sam
> Hi,
>
[quoted text clipped - 33 lines]
> >> > way
> >> > but maybe not.