RAD Studio VCL Reference
|
Saves the contents of the BLOB field to a stream.
procedure SaveToStream(Stream: TStream);
__fastcall SaveToStream(TStream Stream);
Use SaveToStream to copy the contents of a BLOB field to a stream. Specify the name of the stream to which the field's value is saved as the value of the Stream parameter.
var MS: TMemoryStream; begin MS := TMemoryStream.Create; try SQLDataSet1Images.SaveToStream(MS); Image1.Picture.Bitmap.LoadFromStream(MS); finally MS.Free; end; end;
TMemoryStream *pMS = new TMemoryStream; try { SQLDataSet1Images->SaveToStream(pMS); Image1->Picture->Bitmap->LoadFromStream(pMS); } __finally { delete pMS; }
Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
|
What do you think about this topic? Send feedback!
|