ImageEn, unit iexHelperFunctions

TImageEnIO.SaveToBlob

TImageEnIO.SaveToBlob


Declaration


function SaveToBlob(aField : TBlobField;
                    aFileType : TIOFileType;
                    iJpegQuality: integer = 0): Boolean;


Description


Uses streams to set a blob field with an image, optionally setting JPEG_Quality. You must specify a file type, e.g. ioJPEG.
Returns True if saving was successful, or False on error

Note: You must define IE_DB_Helpers in iexHelperFunctions.pas to use this method


Example


// Update the current image in the table with that displayed in our TImageEnView
MyDBTable.Edit;
ImageEnView1.IO.SaveToFileEx(MyDBTableImageField, ioJPEG, 90)
MyDBTableEditDate.AsDateTime := Now;
MyDBTable.Post;