I am trying to extract a zip file in a database image field to disk. For some
reason, the zip file is getting corrupted / truncated. I have code in ASP
which extracts the zip file no problem, so i know it is not corrupted in the
table. Any help would be appreciated.
FileStream fs = new FileStream(sFil ePath + "TestFile.z ip",
FileMode.Create New);
BinaryWriter bw = new BinaryWriter(fs );
byte[] buffer =
Encoding.ASCII. GetBytes(DataRe ader[sField].ToString());
bw.Write(buffer );
bw.Close();
fs.Close();
reason, the zip file is getting corrupted / truncated. I have code in ASP
which extracts the zip file no problem, so i know it is not corrupted in the
table. Any help would be appreciated.
FileStream fs = new FileStream(sFil ePath + "TestFile.z ip",
FileMode.Create New);
BinaryWriter bw = new BinaryWriter(fs );
byte[] buffer =
Encoding.ASCII. GetBytes(DataRe ader[sField].ToString());
bw.Write(buffer );
bw.Close();
fs.Close();
Comment