I'm using ADO to extract data from SQL server. I have an object that runs a stored procedure and returns a recordset successfully.
I'm using GetRows() to populate my SAFEARRAY. I then try to find the Ubound Property using SafeArrayGetUBound and I always retrun zero???
I've not had much experience with SAFEARRAY's does anyone know what I'm doing wrong?
if (m_RSPtr == NULL)
m_vArrRows = m_RSPtr->GetRows(ADODB::adGetRowsRest);
HRESULT hr = SafeArrayGetUBound(m_vArrRows.parray, 1,&m_lUbound);
catch (_com_error e)
ATLTRACE(_T("Exception thrown: %s\n"), (LPCTSTR)e.Description());
Open in new window