Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Saving / Writing Image as a Blob
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Miscellaneous
Thread ID:
01539374
Message ID:
01539973
Views:
141
Blob will be a little more efficient at storage because VFP won't be doing any code page conversions on it ever. But Blob is a new field type for VFP (9 I think) and prior to that you could always store binary data in memos. Both work fine...

+++ Rick ---

>Rick,
>what is the advantage of memo over blob or blob over memo for storing images or is there any?
>
>Thanks,
>John.
>
>
>
>>John,
>>
>>FoxPro tables can simply accept binary data as text, so you can directly store the results from FileToStr() in a memo field as the text is stored as plain ASCII.
>>
>>+++ Rick ---
>>
>>>I need to save a thumbnail of a page and then write it back out later. This code seems to work just fine but I thought I would run it past the brains here to make sure it's the best way and that I won't run into any problems.
>>>Thanks folks.
>>>
create cursor c_test (thumbnail W)
>>>m.Thumbnail = FileToStr('noimage.jpg')
>>>insert into c_test from memvar
>>>* brow
>>>=StrToFile(c_test.thumbnail, 'btest.jpg')
+++ Rick ---

West Wind Technologies
Maui, Hawaii

west-wind.com/
West Wind Message Board
Rick's Web Log
Markdown Monster
---
Making waves on the Web

Where do you want to surf today?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform