J
Jonathan Wood
Guest
I don't know if Microsoft still has any interest in feedback on MFC. Are they still developing it? If anyone knows a good forum to provide such feedback, could you please let me know?
I went to their website but all the feedback links are related to newer technologies.
Specifically, I noticed that the CRecordset class does not define RFX_BigInt_Bulk(), when this seems like an obvious need.
I believe it should look something like this:
void AFXAPI RFX_BigInt_Bulk(CFieldExchange* pFX, LPCTSTR szName, __int64** prgBigIntVals, LONG_PTR** prgLengths)
{
ENSURE_ARG(AfxIsValidAddress(pFX, sizeof(CFieldExchange)));
ENSURE_ARG(AfxIsValidString(szName));
UINT nField;
if (!pFX->IsFieldType(&nField))
return;
ENSURE_ARG(prgBigIntVals != NULL && prgLengths != NULL);
switch (pFX->m_nOperation)
{
case CFieldExchange::AllocMultiRowBuffer:
{
// The buffer pointer better be initialized to NULL
// or cleanup in exceptional cases may fail
ASSERT(*prgBigIntVals == NULL);
ASSERT(*prgLengths == NULL);
int nRowsetSize = pFX->m_prs->GetRowsetSize();
// Allocate buffers to hold data and length
*prgBigIntVals = new __int64[nRowsetSize];
*prgLengths = new LONG_PTR[nRowsetSize];
}
break;
case CFieldExchange:eleteMultiRowBuffer:
delete[] * prgBigIntVals;
*prgBigIntVals = NULL;
delete[] * prgLengths;
*prgLengths = NULL;
break;
default:
AfxRFXBulkDefault(pFX, szName, *prgBigIntVals, *prgLengths,
SQL_C_SBIGINT, sizeof(__int64));
break;
}
}
Jonathan Wood • Black Belt Coder
Continue reading...
I went to their website but all the feedback links are related to newer technologies.
Specifically, I noticed that the CRecordset class does not define RFX_BigInt_Bulk(), when this seems like an obvious need.
I believe it should look something like this:
void AFXAPI RFX_BigInt_Bulk(CFieldExchange* pFX, LPCTSTR szName, __int64** prgBigIntVals, LONG_PTR** prgLengths)
{
ENSURE_ARG(AfxIsValidAddress(pFX, sizeof(CFieldExchange)));
ENSURE_ARG(AfxIsValidString(szName));
UINT nField;
if (!pFX->IsFieldType(&nField))
return;
ENSURE_ARG(prgBigIntVals != NULL && prgLengths != NULL);
switch (pFX->m_nOperation)
{
case CFieldExchange::AllocMultiRowBuffer:
{
// The buffer pointer better be initialized to NULL
// or cleanup in exceptional cases may fail
ASSERT(*prgBigIntVals == NULL);
ASSERT(*prgLengths == NULL);
int nRowsetSize = pFX->m_prs->GetRowsetSize();
// Allocate buffers to hold data and length
*prgBigIntVals = new __int64[nRowsetSize];
*prgLengths = new LONG_PTR[nRowsetSize];
}
break;
case CFieldExchange:eleteMultiRowBuffer:
delete[] * prgBigIntVals;
*prgBigIntVals = NULL;
delete[] * prgLengths;
*prgLengths = NULL;
break;
default:
AfxRFXBulkDefault(pFX, szName, *prgBigIntVals, *prgLengths,
SQL_C_SBIGINT, sizeof(__int64));
break;
}
}
Jonathan Wood • Black Belt Coder
Continue reading...