private DataTable ADODBRecordset_to_ADODataTable(ADODB.Recordset adoRs) { string tableName = "adoTable"; try { tableName = adoRs.Properties["Unique Table"].Value.ToString(); } catch { // No existe el nombre de la tabla. } tableName = (tableName == "") ? "adoTable" : tableName; ADODB.Recordset dummyrs = adoRs.Clone(ADODB.LockTypeEnum.adLockReadOnly); OleDbDataAdapter myDA = new OleDbDataAdapter(); DataSet myDS = new DataSet(); myDA.Fill(myDS, dummyrs, tableName); dummyrs = null; return myDS.Tables[0]; }