General information
Title:
Binary String To File question
I have a VFP8 table that has a memo field. This memo field stores a JPG as binary.
Using C#, how can I extract the memo data from the current record and save it to disk as .JPG?
I tried using:
////////////
string lc_var;
lc_var = dr["empphoto"].ToString();
FileStream oFs = new FileStream(cFileName,FileMode.CreateNew,FileAccess.ReadWrite);
StreamWriter oWriter = new StreamWriter(oFs);
oWriter.Write(lc_var);
oWriter.Flush();
oWriter.Close();
oFs.Close();
////////////
Thanks,
Jerry
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only