>How can i open a file in binary mode?
>I need this because I want to send small chunks of the file through the winsock control.
>
>Thanks in advance
>Héctor L.
In VFP 6 or later, just copy the file to a memory variable with FileToStr(). Then you can get individual bytes with substr().
For older versions of VFP, use the old-fashioned approach (still useful in some situations) of low-level functions: fopen(), fread(), fclose(). fgets() is oriented towards text-files only, so you won't use it here.
HTH, Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)