Open a CrossTab Query as a Recordset

ShaunWillmott

Registered User.
Local time
Today, 07:41
Joined
Dec 21, 2001
Messages
17
Hi,

I'm trying to open a Crosstab query as an ADO Recordset and keep getting Invalid SQL statement expected DELETE, INSERT, PROCEDURE, SELECT or UPDATE.

I have opened lots of Queries before, this is the 1st Xtab.

Can anyone help?

My Code follows:

Dim rstMthDest As ADODB.Recordset
Set cnn = CurrentProject.Connection
Set rstMthDest = New ADODB.Recordset

rstMthDest.Open "qryDestbyMth", cnn

On debug it's the last line I get the error with.

Regards

Shaun
 
Try another query

Select * from crosstab

Then run your ADO against that.
 

Users who are viewing this thread

Back
Top Bottom