Gibberish Pdf file displayed if I transfer using bit stream
Gibberish Pdf file displayed if I transfer using bit stream
am 09.02.2007 20:52:01 von bettys
Hi all,
The following code was suggested by one of the users in this newsgroup when
a pdf file was requested by a user from an asp page. I used the similar code
in my page and the very interesting thing is when the pdf is displayed on the
fly, the whole page is a gibberish code in stead of a normal pdf file. But it
displays fine if I just use a link to a file on the page. Can you tell me
what's the possible reason will cause this problem?
Thank you.
> if objFSO.FileExists(strFilePath) AND ok then
> Set objStream = Server.CreateObject("ADODB.Stream")
> objStream.Open
> objStream.Type = 1
> objStream.LoadFromFile strFilePath
> Response.Buffer = false
> Response.ContentType = "application/pdf"
> Response.AddHeader "Content-Type", "application/pdf"
> Response.AddHeader "Content-Disposition","inline;filename="&once
> Response.BinaryWrite objStream.Read
> Response.Flush
> objStream.Close
> Set objStream = Nothing
> else
> response.write "Sorry, nonexisting file"
> end if
> Set objFSO = Nothing
> Response.end
> end if
--
Betty
RE: Gibberish Pdf file displayed if I transfer using bit stream
am 09.02.2007 20:56:01 von bettys
Oh, I forgot to tell you that I removed the code
Response.Buffer = false
since I set up this is true some where, it tells me that I cannot reset to
false.
So I removed that, not sure if this will impact on the result, I guess not?
--
Betty
"c676228" wrote:
> Hi all,
> The following code was suggested by one of the users in this newsgroup when
> a pdf file was requested by a user from an asp page. I used the similar code
> in my page and the very interesting thing is when the pdf is displayed on the
> fly, the whole page is a gibberish code in stead of a normal pdf file. But it
> displays fine if I just use a link to a file on the page. Can you tell me
> what's the possible reason will cause this problem?
> Thank you.
>
>
> > if objFSO.FileExists(strFilePath) AND ok then
> > Set objStream = Server.CreateObject("ADODB.Stream")
> > objStream.Open
> > objStream.Type = 1
> > objStream.LoadFromFile strFilePath
> > Response.Buffer = false
> > Response.ContentType = "application/pdf"
> > Response.AddHeader "Content-Type", "application/pdf"
> > Response.AddHeader "Content-Disposition","inline;filename="&once
> > Response.BinaryWrite objStream.Read
> > Response.Flush
> > objStream.Close
> > Set objStream = Nothing
> > else
> > response.write "Sorry, nonexisting file"
> > end if
> > Set objFSO = Nothing
> > Response.end
> > end if
>
> --
> Betty
Re: Gibberish Pdf file displayed if I transfer using bit stream
am 09.02.2007 22:09:49 von Anthony Jones
"c676228" wrote in message
news:8126178E-50C6-4FBE-9A7E-F2672EC3C323@microsoft.com...
> Hi all,
> The following code was suggested by one of the users in this newsgroup
when
> a pdf file was requested by a user from an asp page. I used the similar
code
> in my page and the very interesting thing is when the pdf is displayed on
the
> fly, the whole page is a gibberish code in stead of a normal pdf file. But
it
> displays fine if I just use a link to a file on the page. Can you tell me
> what's the possible reason will cause this problem?
> Thank you.
>
>
> > if objFSO.FileExists(strFilePath) AND ok then
> > Set objStream = Server.CreateObject("ADODB.Stream")
> > objStream.Open
> > objStream.Type = 1
> > objStream.LoadFromFile strFilePath
> > Response.Buffer = false
> > Response.ContentType = "application/pdf"
> > Response.AddHeader "Content-Type", "application/pdf"
> > Response.AddHeader "Content-Disposition","inline;filename="&once
> > Response.BinaryWrite objStream.Read
> > Response.Flush
> > objStream.Close
> > Set objStream = Nothing
> > else
> > response.write "Sorry, nonexisting file"
> > end if
> > Set objFSO = Nothing
> > Response.end
> > end if
>
Do you have other include files in the ASP code?
Do you have other content that is being sent before this code?
The inability to use Response.Buffer = false would indicate that you do.
In the case above Response.Buffer = false in unnecessary since you write the
complete contents of the stream to the response in one call to BinaryWrite.
On IIS6 the default response buffer is 4MB so if your PDF is potentially
larger you will either need to increase this limit or chunk out the PDF
contents.
This is my stock function for doing this:-
Sub SendFileToResponse(FilePath, FileName)
Const clChunkSize = 1048576 ' 1MB
Dim oStream, i
Response.Buffer = False
Response.ContentType = "application/octet-stream"
Response.AddHeader "Content-Disposition", _
"Filename=" & FileName
Set oStream = Server.CreateObject("ADODB.Stream")
oStream.Type = 1 ' Binary
oStream.Open
oStream.LoadFromFile FilePath
For i = 1 To oStream.Size \ clChunkSize
Response.BinaryWrite oStream.Read(clChunkSize)
Next
If (oStream.Size Mod clChunkSize) <> 0 Then
Response.BinaryWrite oStream.Read(oStream.Size Mod clChunkSize)
End If
oStream.Close
End Sub
You would call this function as:-
SendFileToResponse strFilePath, once
since it chunks out the content there is no need to worry about buffer size.
However before you can use it you will need to look at what is happening
earlier in your page that is already placing unwanted content in the
response.
Anthony.
> --
> Betty
Re: Gibberish Pdf file displayed if I transfer using bit stream
am 09.02.2007 23:04:00 von bettys
Hi Anthony,
we us IIS 5.0
Thanks for your suggestion. I do have include file, but it has nothing about
buffer set up, no html code, only database connection include file. And I
went to IIS virtual direcotry and saw default configuration for the
application is "enable buffer", so I unchecked this option and it no longer
complains the statement "Response.Buffer = false ".
My pdf file is not big at all, it's less than 90KB. Now after I changed the
code, it gives me very informational error message like this:
Response object error 'ASP 0156 : 80004005'
Header Error
/DeliverPdf.asp, line 48 'which is Response.ContentType =
"application/octet-stream"
The HTTP headers are already written to the client browser. Any HTTP header
modifications must be made before writing page content.
--'end of the eeror message
Then I thought it is because we have default HTTP headers in virtual
directoy, which is something generated by the system like this:
P3P: xxxxx
x-powered by: asp.net
Then I removed that default header and it still display the same error
message.
I don't get this.
My code is as follow:
----deleiverpdf.asp
'init_test is database connection file
<%
cmdTemp.CommandText="a sql comand to fetch record from system based filename"
dim FileName, strFilePath
'Response.End
Set pdf_info = Server.CreateObject("ADODB.Recordset")
pdf_info.Open cmdTemp, , adOpenKeyset, adLockOptimistic
If pdf_info.EOF Then
response.redirect "/noPicFound404.gif"
Else
pdf_info.MoveFirst()
'Response.Write "File Name: " & pdf_info("pdfFileName")
OK=False
If Request("FileName")=Trim(pdf_info("pdfFileName")) Then
strFilePath = Server.MapPath(pdf_info("TempPdfFilePath"))& "\" &
Request("FileName")
'Response.Write " Path " & strFilePath
Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
If CInt(pdf_info("MinElapsed")) < CInt(pdf_info("ExpTime")) then
OK=true
End If
If objFSO.FileExists(strFilePath) and OK Then
Set objStream = Server.CreateObject("ADODB.Stream")
objStream.Open
objStream.Type = 1
objStream.LoadFromFile strFilePath
Response.Buffer = false
Response.ContentType = "application/octet-stream"
Response.AddHeader "Content-Type", "application/pdf"
Response.AddHeader
"Content-Disposition","inline;filename="&Request("FileName") %>
<%Response.BinaryWrite objStream.Read
Response.Flush
objStream.Close
Set objStream = Nothing
'Response.Write "I am inside pdf delivery."
Else
response.write "Sorry, the file doesn't exist."
End If
Set objFSO = Nothing
Response.end
End If 'End If FileName is the same as in the database system
End If 'End If pdf_info is EOF
'End Function
Response.Write FileName & "
"
Response.Write strFilePath & "
"
conn.Close
set conn=Nothing
cmdTemp.Close
set cmdTemp=Nothing
%>
--
Betty
"Anthony Jones" wrote:
>
> "c676228" wrote in message
> news:8126178E-50C6-4FBE-9A7E-F2672EC3C323@microsoft.com...
> > Hi all,
> > The following code was suggested by one of the users in this newsgroup
> when
> > a pdf file was requested by a user from an asp page. I used the similar
> code
> > in my page and the very interesting thing is when the pdf is displayed on
> the
> > fly, the whole page is a gibberish code in stead of a normal pdf file. But
> it
> > displays fine if I just use a link to a file on the page. Can you tell me
> > what's the possible reason will cause this problem?
> > Thank you.
> >
> >
> > > if objFSO.FileExists(strFilePath) AND ok then
> > > Set objStream = Server.CreateObject("ADODB.Stream")
> > > objStream.Open
> > > objStream.Type = 1
> > > objStream.LoadFromFile strFilePath
> > > Response.Buffer = false
> > > Response.ContentType = "application/pdf"
> > > Response.AddHeader "Content-Type", "application/pdf"
> > > Response.AddHeader "Content-Disposition","inline;filename="&once
> > > Response.BinaryWrite objStream.Read
> > > Response.Flush
> > > objStream.Close
> > > Set objStream = Nothing
> > > else
> > > response.write "Sorry, nonexisting file"
> > > end if
> > > Set objFSO = Nothing
> > > Response.end
> > > end if
> >
>
> Do you have other include files in the ASP code?
> Do you have other content that is being sent before this code?
> The inability to use Response.Buffer = false would indicate that you do.
>
> In the case above Response.Buffer = false in unnecessary since you write the
> complete contents of the stream to the response in one call to BinaryWrite.
>
> On IIS6 the default response buffer is 4MB so if your PDF is potentially
> larger you will either need to increase this limit or chunk out the PDF
> contents.
>
> This is my stock function for doing this:-
>
> Sub SendFileToResponse(FilePath, FileName)
>
> Const clChunkSize = 1048576 ' 1MB
>
> Dim oStream, i
> Response.Buffer = False
>
> Response.ContentType = "application/octet-stream"
> Response.AddHeader "Content-Disposition", _
> "Filename=" & FileName
>
> Set oStream = Server.CreateObject("ADODB.Stream")
> oStream.Type = 1 ' Binary
> oStream.Open
> oStream.LoadFromFile FilePath
>
> For i = 1 To oStream.Size \ clChunkSize
> Response.BinaryWrite oStream.Read(clChunkSize)
> Next
> If (oStream.Size Mod clChunkSize) <> 0 Then
> Response.BinaryWrite oStream.Read(oStream.Size Mod clChunkSize)
> End If
> oStream.Close
>
> End Sub
>
> You would call this function as:-
>
> SendFileToResponse strFilePath, once
>
> since it chunks out the content there is no need to worry about buffer size.
> However before you can use it you will need to look at what is happening
> earlier in your page that is already placing unwanted content in the
> response.
>
> Anthony.
>
>
> > --
> > Betty
>
>
>
Re: Gibberish Pdf file displayed if I transfer using bit stream
am 09.02.2007 23:25:50 von Anthony Jones
"c676228" wrote in message
news:FFDBA054-61DE-4693-9AA0-8ACAA1B4BB89@microsoft.com...
> Hi Anthony,
> we us IIS 5.0
> Thanks for your suggestion. I do have include file, but it has nothing
about
> buffer set up, no html code, only database connection include file. And I
> went to IIS virtual direcotry and saw default configuration for the
> application is "enable buffer", so I unchecked this option and it no
longer
> complains the statement "Response.Buffer = false ".
I strongly recommend you turn that back on again.
> My pdf file is not big at all, it's less than 90KB. Now after I changed
the
> code, it gives me very informational error message like this:
> Response object error 'ASP 0156 : 80004005'
>
> Header Error
>
> /DeliverPdf.asp, line 48 'which is Response.ContentType =
> "application/octet-stream"
>
> The HTTP headers are already written to the client browser. Any HTTP
header
> modifications must be made before writing page content.
> --'end of the eeror message
> Then I thought it is because we have default HTTP headers in virtual
> directoy, which is something generated by the system like this:
> P3P: xxxxx
> x-powered by: asp.net
> Then I removed that default header and it still display the same error
> message.
> I don't get this.
>
> My code is as follow:
> ----deleiverpdf.asp
>
> 'init_test is database connection file
>
The above is part of the problem you've started to send html content but you
want to send a pdf. Your page should only contain ASP code in <% %>. There
should be no HTML mark up in it at all.
> <%
> cmdTemp.CommandText="a sql comand to fetch record from system based
filename"
> dim FileName, strFilePath
> 'Response.End
> Set pdf_info = Server.CreateObject("ADODB.Recordset")
> pdf_info.Open cmdTemp, , adOpenKeyset, adLockOptimistic
> If pdf_info.EOF Then
> response.redirect "/noPicFound404.gif"
> Else
> pdf_info.MoveFirst()
> 'Response.Write "File Name: " & pdf_info("pdfFileName")
> OK=False
> If Request("FileName")=Trim(pdf_info("pdfFileName")) Then
> strFilePath = Server.MapPath(pdf_info("TempPdfFilePath"))& "\" &
> Request("FileName")
> 'Response.Write " Path " & strFilePath
> Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
> If CInt(pdf_info("MinElapsed")) < CInt(pdf_info("ExpTime")) then
> OK=true
> End If
> If objFSO.FileExists(strFilePath) and OK Then
> Set objStream = Server.CreateObject("ADODB.Stream")
> objStream.Open
> objStream.Type = 1
> objStream.LoadFromFile strFilePath
> Response.Buffer = false
> Response.ContentType = "application/octet-stream"
> Response.AddHeader "Content-Type", "application/pdf"
> Response.AddHeader
> "Content-Disposition","inline;filename="&Request("FileName")
Get rid of this bit of markup also
%>
>
> <%
> Response.BinaryWrite objStream.Read
> Response.Flush
> objStream.Close
> Set objStream = Nothing
> 'Response.Write "I am inside pdf delivery."
> Else
> response.write "Sorry, the file doesn't exist."
> End If
> Set objFSO = Nothing
> Response.end
> End If 'End If FileName is the same as in the database system
>
> End If 'End If pdf_info is EOF
>
>
> 'End Function
> Response.Write FileName & "
"
> Response.Write strFilePath & "
"
> conn.Close
> set conn=Nothing
> cmdTemp.Close
> set cmdTemp=Nothing
> %>
And this bit as well:
>
>
> --
> Betty
>
>
> "Anthony Jones" wrote:
>
> >
> > "c676228" wrote in message
> > news:8126178E-50C6-4FBE-9A7E-F2672EC3C323@microsoft.com...
> > > Hi all,
> > > The following code was suggested by one of the users in this newsgroup
> > when
> > > a pdf file was requested by a user from an asp page. I used the
similar
> > code
> > > in my page and the very interesting thing is when the pdf is displayed
on
> > the
> > > fly, the whole page is a gibberish code in stead of a normal pdf file.
But
> > it
> > > displays fine if I just use a link to a file on the page. Can you tell
me
> > > what's the possible reason will cause this problem?
> > > Thank you.
> > >
> > >
> > > > if objFSO.FileExists(strFilePath) AND ok then
> > > > Set objStream = Server.CreateObject("ADODB.Stream")
> > > > objStream.Open
> > > > objStream.Type = 1
> > > > objStream.LoadFromFile strFilePath
> > > > Response.Buffer = false
> > > > Response.ContentType = "application/pdf"
> > > > Response.AddHeader "Content-Type", "application/pdf"
> > > > Response.AddHeader "Content-Disposition","inline;filename="&once
> > > > Response.BinaryWrite objStream.Read
> > > > Response.Flush
> > > > objStream.Close
> > > > Set objStream = Nothing
> > > > else
> > > > response.write "Sorry, nonexisting file"
> > > > end if
> > > > Set objFSO = Nothing
> > > > Response.end
> > > > end if
> > >
> >
> > Do you have other include files in the ASP code?
> > Do you have other content that is being sent before this code?
> > The inability to use Response.Buffer = false would indicate that you do.
> >
> > In the case above Response.Buffer = false in unnecessary since you write
the
> > complete contents of the stream to the response in one call to
BinaryWrite.
> >
> > On IIS6 the default response buffer is 4MB so if your PDF is potentially
> > larger you will either need to increase this limit or chunk out the PDF
> > contents.
> >
> > This is my stock function for doing this:-
> >
> > Sub SendFileToResponse(FilePath, FileName)
> >
> > Const clChunkSize = 1048576 ' 1MB
> >
> > Dim oStream, i
> > Response.Buffer = False
> >
> > Response.ContentType = "application/octet-stream"
> > Response.AddHeader "Content-Disposition", _
> > "Filename=" & FileName
> >
> > Set oStream = Server.CreateObject("ADODB.Stream")
> > oStream.Type = 1 ' Binary
> > oStream.Open
> > oStream.LoadFromFile FilePath
> >
> > For i = 1 To oStream.Size \ clChunkSize
> > Response.BinaryWrite oStream.Read(clChunkSize)
> > Next
> > If (oStream.Size Mod clChunkSize) <> 0 Then
> > Response.BinaryWrite oStream.Read(oStream.Size Mod clChunkSize)
> > End If
> > oStream.Close
> >
> > End Sub
> >
> > You would call this function as:-
> >
> > SendFileToResponse strFilePath, once
> >
> > since it chunks out the content there is no need to worry about buffer
size.
> > However before you can use it you will need to look at what is happening
> > earlier in your page that is already placing unwanted content in the
> > response.
> >
> > Anthony.
> >
> >
> > > --
> > > Betty
> >
> >
> >
Re: Gibberish Pdf file displayed if I transfer using bit stream
am 10.02.2007 00:03:01 von bettys
Hooray! Anthony,
That works after I removed the html tag. Mm, I had another good lession.
Thank you.
--
Betty
"Anthony Jones" wrote:
>
> "c676228" wrote in message
> news:FFDBA054-61DE-4693-9AA0-8ACAA1B4BB89@microsoft.com...
> > Hi Anthony,
> > we us IIS 5.0
> > Thanks for your suggestion. I do have include file, but it has nothing
> about
> > buffer set up, no html code, only database connection include file. And I
> > went to IIS virtual direcotry and saw default configuration for the
> > application is "enable buffer", so I unchecked this option and it no
> longer
> > complains the statement "Response.Buffer = false ".
>
> I strongly recommend you turn that back on again.
>
> > My pdf file is not big at all, it's less than 90KB. Now after I changed
> the
> > code, it gives me very informational error message like this:
> > Response object error 'ASP 0156 : 80004005'
> >
> > Header Error
> >
> > /DeliverPdf.asp, line 48 'which is Response.ContentType =
> > "application/octet-stream"
> >
> > The HTTP headers are already written to the client browser. Any HTTP
> header
> > modifications must be made before writing page content.
> > --'end of the eeror message
> > Then I thought it is because we have default HTTP headers in virtual
> > directoy, which is something generated by the system like this:
> > P3P: xxxxx
> > x-powered by: asp.net
> > Then I removed that default header and it still display the same error
> > message.
> > I don't get this.
> >
> > My code is as follow:
> > ----deleiverpdf.asp
> >
> > 'init_test is database connection file
> >
>
> The above is part of the problem you've started to send html content but you
> want to send a pdf. Your page should only contain ASP code in <% %>. There
> should be no HTML mark up in it at all.
>
> > <%
> > cmdTemp.CommandText="a sql comand to fetch record from system based
> filename"
> > dim FileName, strFilePath
> > 'Response.End
> > Set pdf_info = Server.CreateObject("ADODB.Recordset")
> > pdf_info.Open cmdTemp, , adOpenKeyset, adLockOptimistic
> > If pdf_info.EOF Then
> > response.redirect "/noPicFound404.gif"
> > Else
> > pdf_info.MoveFirst()
> > 'Response.Write "File Name: " & pdf_info("pdfFileName")
> > OK=False
> > If Request("FileName")=Trim(pdf_info("pdfFileName")) Then
> > strFilePath = Server.MapPath(pdf_info("TempPdfFilePath"))& "\" &
> > Request("FileName")
> > 'Response.Write " Path " & strFilePath
> > Set objFSO = Server.CreateObject("Scripting.FileSystemObject")
> > If CInt(pdf_info("MinElapsed")) < CInt(pdf_info("ExpTime")) then
> > OK=true
> > End If
> > If objFSO.FileExists(strFilePath) and OK Then
> > Set objStream = Server.CreateObject("ADODB.Stream")
> > objStream.Open
> > objStream.Type = 1
> > objStream.LoadFromFile strFilePath
> > Response.Buffer = false
> > Response.ContentType = "application/octet-stream"
> > Response.AddHeader "Content-Type", "application/pdf"
> > Response.AddHeader
> > "Content-Disposition","inline;filename="&Request("FileName")
>
> Get rid of this bit of markup also
>
> %>
> >
> > <%
>
>
> > Response.BinaryWrite objStream.Read
> > Response.Flush
> > objStream.Close
> > Set objStream = Nothing
> > 'Response.Write "I am inside pdf delivery."
> > Else
> > response.write "Sorry, the file doesn't exist."
> > End If
> > Set objFSO = Nothing
> > Response.end
> > End If 'End If FileName is the same as in the database system
> >
> > End If 'End If pdf_info is EOF
> >
> >
> > 'End Function
> > Response.Write FileName & "
"
> > Response.Write strFilePath & "
"
> > conn.Close
> > set conn=Nothing
> > cmdTemp.Close
> > set cmdTemp=Nothing
> > %>
>
> And this bit as well:
>
> >
> >
>
>
>
>
> > --
> > Betty
> >
> >
> > "Anthony Jones" wrote:
> >
> > >
> > > "c676228" wrote in message
> > > news:8126178E-50C6-4FBE-9A7E-F2672EC3C323@microsoft.com...
> > > > Hi all,
> > > > The following code was suggested by one of the users in this newsgroup
> > > when
> > > > a pdf file was requested by a user from an asp page. I used the
> similar
> > > code
> > > > in my page and the very interesting thing is when the pdf is displayed
> on
> > > the
> > > > fly, the whole page is a gibberish code in stead of a normal pdf file.
> But
> > > it
> > > > displays fine if I just use a link to a file on the page. Can you tell
> me
> > > > what's the possible reason will cause this problem?
> > > > Thank you.
> > > >
> > > >
> > > > > if objFSO.FileExists(strFilePath) AND ok then
> > > > > Set objStream = Server.CreateObject("ADODB.Stream")
> > > > > objStream.Open
> > > > > objStream.Type = 1
> > > > > objStream.LoadFromFile strFilePath
> > > > > Response.Buffer = false
> > > > > Response.ContentType = "application/pdf"
> > > > > Response.AddHeader "Content-Type", "application/pdf"
> > > > > Response.AddHeader "Content-Disposition","inline;filename="&once
> > > > > Response.BinaryWrite objStream.Read
> > > > > Response.Flush
> > > > > objStream.Close
> > > > > Set objStream = Nothing
> > > > > else
> > > > > response.write "Sorry, nonexisting file"
> > > > > end if
> > > > > Set objFSO = Nothing
> > > > > Response.end
> > > > > end if
> > > >
> > >
> > > Do you have other include files in the ASP code?
> > > Do you have other content that is being sent before this code?
> > > The inability to use Response.Buffer = false would indicate that you do.
> > >
> > > In the case above Response.Buffer = false in unnecessary since you write
> the
> > > complete contents of the stream to the response in one call to
> BinaryWrite.
> > >
> > > On IIS6 the default response buffer is 4MB so if your PDF is potentially
> > > larger you will either need to increase this limit or chunk out the PDF
> > > contents.
> > >
> > > This is my stock function for doing this:-
> > >
> > > Sub SendFileToResponse(FilePath, FileName)
> > >
> > > Const clChunkSize = 1048576 ' 1MB
> > >
> > > Dim oStream, i
> > > Response.Buffer = False
> > >
> > > Response.ContentType = "application/octet-stream"
> > > Response.AddHeader "Content-Disposition", _
> > > "Filename=" & FileName
> > >
> > > Set oStream = Server.CreateObject("ADODB.Stream")
> > > oStream.Type = 1 ' Binary
> > > oStream.Open
> > > oStream.LoadFromFile FilePath
> > >
> > > For i = 1 To oStream.Size \ clChunkSize
> > > Response.BinaryWrite oStream.Read(clChunkSize)
> > > Next
> > > If (oStream.Size Mod clChunkSize) <> 0 Then
> > > Response.BinaryWrite oStream.Read(oStream.Size Mod clChunkSize)
> > > End If
> > > oStream.Close
> > >
> > > End Sub
> > >
> > > You would call this function as:-
> > >
> > > SendFileToResponse strFilePath, once
> > >
> > > since it chunks out the content there is no need to worry about buffer
> size.
> > > However before you can use it you will need to look at what is happening
> > > earlier in your page that is already placing unwanted content in the
> > > response.
> > >
> > > Anthony.
> > >
> > >
> > > > --
> > > > Betty
> > >
> > >
> > >
>
>
>