I've updated to 6.1.4 (from 5.7.27) and execute the code below. It is important that a ftWideMemo is included.
DataSetGetRecordCount delivers the value 1.
DataSetGetFieldValue delivers a fix value for each field.
Code: Select all
lDataSet := TVirtualDataSet.Create(nil);
try
lDataSet.OnGetRecordCount := DataSetGetRecordCount;
lDataSet.OnGetFieldValue := DataSetGetFieldValue;
lDataSet.FieldDefs.Add('id', ftInteger);
lDataSet.FieldDefs.Add('name', ftWideString, 50);
lDataSet.FieldDefs.Add('info', ftWideMemo);
lDataSet.Active := True;
lDataSet.Edit; // A/V in MemData.TBlob.SetAsWideString
finally
FreeAndNil(lDataSet);
end;
I thought it was fixed with 6.0.1 (Bug with reading Memo as WideMemo is fixed).
Regards, Jan