To read and output the binary, you can simply use the ADODB.Stream object.
See the MSDN ADODB.Stream library:
http://msdn.microsoft.com/en-us/library/ms675032(VS.85).aspx
Here is an example I found from Expert Exchange:
Function ReadBinaryFile(strFileName) on error resume next Set oStream = Server.CreateObject("ADODB.Stream") if Err.Number <> 0 then ReadBinaryFile=Err.Description Err.Clear exit function end if oStream.Type = 1 oStream.Open oStream.LoadFromFile strFileName if Err.Number<>0 then ReadBinaryFile=Err.Description Err.Clear exit function end if ReadBinaryFile=oStream.Read oStream.Close set oStream = nothing if Err.Number<>0 then ReadBinaryFile=Err.Description End Function
source share