Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do I use the picture data type?
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01146038
Message ID:
01146061
Views:
21
What about using the 'G' (General) field type...or is that actually the same thing as the memo/binary?

>The 'P' field type cannot be used for anything because it is not implemented. You choices is to store pictures in the memo/binary or keep them on disk and store only file name in the table. The second one is preferable because it allows to avoid memo bloat and corruption.
>
>>I need to store an image for each person in a table of users. I was going to use a binary memo field (fieldname m nocptran) but noticed that Fox had a data type of P that I've never used.
>>
>>In experimenting with this, I created a cursor with one field of p data type. However, I can't figure out what it wants. I've tried the following:
>>
>>create cursor temp (pix p)
>>
>>append blank
>>replace pix with filetostr("c:\temp\image1.jpg")
>>replace pix with getpict()
>>
>>... and even
>>
>>oImage = createobject("Image")
>>oImage.Picture = getpict()
>>repl pix with oImage
>>
>>
>>Each time I get an data type mismatch. The Fox 8.0 help seems to be pretty quiet on the subject of the picture memo type.
>>
>>Can someone help me understand what it is used for and how to use it? Also, is there an advantage/disadvantage to storing an image in a binary memo as opposed to a picture memo?
>>
>>Thanks for your help!
ICQ 10556 (ya), 254117
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform