Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 1.0 and 1.1 > ASP.NET 1.0 and 1.1 Professional
|
ASP.NET 1.0 and 1.1 Professional For advanced ASP.NET 1.x coders. Beginning-level questions will be redirected to other forums. NOT for "classic" ASP 3 or the newer ASP.NET 2.0 and 3.5
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Professional section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 5th, 2006, 01:50 AM
Friend of Wrox
 
Join Date: May 2006
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default Urgent: word file on aspx page from sql server

I needed to upload word document file to sql server. so i have converted word file to byte array than saved to sql server image type coloumn. Now i need to retrive that file and to display it on aspx page as well as facilities to download to it. I am able to download it but fail to display properly on aspx page.
If anybody help me?

Bijgupt
__________________
Bijgupt
 
Old October 5th, 2006, 01:52 AM
Friend of Wrox
 
Join Date: May 2006
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I am using ASP.Net 1.1

Bijgupt
 
Old November 4th, 2006, 01:55 AM
Friend of Wrox
 
Join Date: May 2006
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Is it possible????????

Bijgupt
 
Old November 8th, 2006, 08:37 AM
Authorized User
 
Join Date: Aug 2006
Posts: 26
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Response.ClearContent()
        Response.ClearHeaders()
        Response.ContentType = "application/Ms-Word"
        Response.WriteFile(Server.MapPath("xyz.pdf"))
        Response.Flush()
        Response.Close()

 
Old November 9th, 2006, 09:52 AM
Friend of Wrox
 
Join Date: May 2006
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i've already tried above code, it causes to download the file.But i want to display the content on aspx page.

Bijgupt
 
Old November 15th, 2006, 07:27 AM
Authorized User
 
Join Date: Aug 2006
Posts: 26
Thanks: 0
Thanked 0 Times in 0 Posts
Default

if u use pdf it will open directly
but if any ms product it will causes to download








Similar Threads
Thread Thread Starter Forum Replies Last Post
how to Export to Word file from aspx page ??? jay4ever_2000 ASP.NET 1.0 and 1.1 Professional 1 April 21st, 2006 12:03 PM
How to insert date in Sql Server through aspx page jay4ever_2000 ASP.NET 1.0 and 1.1 Professional 4 February 20th, 2006 08:53 AM
URGENT:Connecting SQL server through Proxy server abhowal Pro VB Databases 2 January 9th, 2006 01:47 PM
URGENT:Connecting SQL server through Proxy server abhowal SQL Server 2000 3 November 30th, 2005 04:22 AM
Saving Word File In SQL Server abdul_wasie Classic ASP Databases 0 May 20th, 2005 06:05 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.