Subject Re: [IBO] TBlobfields in TIBOQuery
Author Geoff Worboys
> I want to Fill a TBitmap from a Blobfield using a TIBOQuery.
> With a TIB_Query I could do it well with
> Field[2].AssignTo(myBitmap). But with TIBOQuery I get a
> TField, not a TIB_Column.

I notice in the VCL online help its says...
"Tip: Different types of dataset use different classes of BLOB
streams. It is usually a better idea to call the dataset's
CreateBlobStream method than to call the BLOB stream constructor."

This led me to the IBO source where...

function TIBODataset.CreateBlobStream(
Field: TField;
Mode: TBlobStreamMode ): TStream;
Result := TIBOBlobStream.Create( Field as TBlobField, Mode );

So either call the dataset CreateBlobStream (which makes the code more
generic) or use TIBOBlobStream.Create directly.


Geoff Worboys
Telesis Computing