ObjStream

cliffdover88

New Member
Hi, I'm using this code right now to retrieve files out from an access database:<BR><BR><BR> Sub Page_Load(sender As Object, e As EventArgs)<BR> Dim imgid as String = Request.QueryString("id")<BR> Dim OleDbText as String = "SELECT ID, Name, My_File, File_Type FROM Files WHERE ID=" & imgid <BR> trace.write(OleDbText)<BR> <BR> Dim dr As OleDbDataReader = MyCommand.ExecuteReader()<BR> If dr.Read()<BR> Response.ContentType = (dr.Item(("File_Type")).ToString())<BR> Response.BinaryWrite(dr.item("My_File"))<BR> End If <BR> objConnection.Close()<BR> End Sub<BR><BR>But what I would like to do is to modify this code so that can retrieve the files out from a folder by using a path stored in the database. I know that I can do this with OjbStream in ASP, but I don't know how to do it in ASPX, so if someone know how to do it please help. Thank you very much for your time.
 
Back
Top