Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Extract BMP pic from Memo field with binary data
Message
De
27/04/2008 11:55:15
 
 
À
27/04/2008 04:24:44
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01313308
Message ID:
01313366
Vues:
11
>Hi Sergey,
>
>I have tried to use STRTOFILE but it did not work with data saved by createbinary. It worked only when I did this:
>
>USE enroll
>locate
>lcBmpFile = "C:\fgr\fgricons\test.bmp"
>REPLACE template WITH filetostr(lcBmpFile)    && template is a Memo binary
>
>lcBmpFile = "whatever.bmp"
>STRTOFILE(template, lcBmpFile)
>
>&& This one works, however when I save the image using createbinary() in template Memo, STRTOFILE does not work
>
>replace enroll.template WITH (CREATEBINARY(tpt.tpt))    && tpt is a template.
>
>
>What do you think I should do?
>
>Thanks,
>
>Bob


Try :

USE mytable
lcBmpFile = "whatever.bmp"
STRTOFILE("" + PicField, lcBmpFile)


Or try using CAST() to convert the contents.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform