Local oRS as AdoDB.Recordset,oRS2 as AdoDB.Recordset,oCon as AdoDB.Connection oCon = CreateObject('ADODB.connection') oCon.ConnectionString = "Provider=VFPOLEDB;Data Source="+_samples+"data\testdata.dbc" oCon.Open oRS = oCon.Execute('select * from employee') oRs.Save('disconnectme.rst') oRS2 = CreateObject('ADODB.Recordset') oRs2.Open('disconnectme.rst') oExcel = Createobject('Excel.Application') With oExcel .Workbooks.Add .Visible = .T. .ActiveWorkbook.ActiveSheet.QueryTables.Add( oRS2, .Range("A1")).Refresh Endwith oRs2.Close Erase 'disconnectme.rst'Also check passing a table/view in FoxyClasses.