On May 28, 2006, at 3:12 PM, Long Huynh wrote:
I found an example in Project.rbp. It shows to
display an image file from a Blob data field you have
to write it to an temporary file before you can
display on the ImageWell.
if ProductImageWell.Image <> nil then
// FolderItem of the Temporary Image
f = TemporaryFolder.Child("Order Temp
Image.jpg")
// Save the Image to the File
f.SaveAsJPEG ProductImageWell.Image
// Read it back in if it exists
if f.Exists then
bin = f.OpenAsBinaryFile
if bin <> nil then
// Read Image
imageData = bin.Read(bin.Length)
bin.Close
end if
end if
end if
Why is it so complecated?
Because when we wrote the example there isn't a built-in way in RB to
display a picture starting from a string buffer, but only from a
FolderItem.
I am not sure if this feature has been added in recent versions of RB.
This complication has nothing to do this the database or with BLOB
columns.
---
Marco Bambini
http://www.sqlabs.net
http://www.sqlabs.net/blog/
_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>
Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>