Thnks for responding...
I passed by opening a new window and then open the pdf directly in that
window...so the dialog mode OPEN/SAVE/CANCEL doesen't appear, but it work
fine.
This is the code:
ASPX
<script language="vbscr ipt" type="text/vbscript">
sub NewWindow()
window.open("PD F.aspx")
end sub
</script>
<input type="button" onclick="NewWin dow()" class="button"
causesvalidatio n="false" value="Dowload"/>
C# code behind
protected void Page_Load(objec t sender, EventArgs e)
{
Response.Conten tType = "applicatio n/pdf";
Response.Clear( );
Response.Transm itFile(PATH...) ;
Response.End();
}
"Winista" wrote:
r u getting this error on server side or on client side when user tries to
open the downloaded content.
"comick" <co****@discuss ions.microsoft. comwrote in message
news:DE******** *************** ***********@mic rosoft.com...
Hello all,
i have a asp.net c# web app 2.0
I have a pdf generation with a third part sw, but i cant download pdf in a
new window, from a folder inside my web site.
The code i try to use is this:
..pdf Generation..
Response.Clear( );
Response.Conten tType = "applicatio n/pdf";
HttpContext.Cur rent.Response.A ddHeader("conte nt-disposition", "attachment ;
filename=test.p df");
Response.Transm itFile(@"c:\\.. .path..test.pdf ");
pdf tell me that cannot find the file or is corrupt. I tryed the option
inline instead of attachment but nothing changed.
Anyone have some help? Thanks a lot