?
Solved

aspx need help to link a doc or excel

Posted on 2012-03-20
3
Medium Priority
?
331 Views
Last Modified: 2012-08-14
I am developing a web based app using visual studio 8 and aspx. One page has buttons that need to deliver MS Word docs and Excel spreadsheets to the user.

note: for now I am working offline and store the docs on my c drive in folder named temp
so path is "c:\temp\test.doc"

when I use   Response.Redirect("C:/temp/test.doc")

it does not do anything - it says IE cannot find the webpage


I don't care how the delivery of word or excel takes place - even if user is just propmted to save it on their pc
0
Comment
Question by:LBecerra
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 40

Assisted Solution

by:Kyle Abrahams
Kyle Abrahams earned 400 total points
ID: 37743098
Try

Response.Redirect(Server.MapPath(@"C:\temp\test.doc"))
0
 
LVL 13

Accepted Solution

by:
Rick earned 1200 total points
ID: 37743178
Store the documents in a folder within your web application.

For example, if your application is in C:\Temp\WebApp1, create a folder called Docs (C:\Temp\WebApp1\Docs) to store your documents; then:

Response.Redirect("~/Docs/test.doc")
0
 

Author Closing Comment

by:LBecerra
ID: 37744176
Thank you both. The solution with folder in web will answer my next step of how to redirect when I get on a web server and worked. The other solution had difficulties with our network.
0

Featured Post

Three Reasons Why Backup is Strategic

Backup is strategic to your business because your data is strategic to your business. Without backup, your business will fail. This white paper explains why it is vital for you to design and immediately execute a backup strategy to protect 100 percent of your data.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The System Center Operations Manager 2012, known as SCOM, is a part of the Microsoft system center product that provides the user with infrastructure monitoring and application performance monitoring. SCOM monitors:   Windows or UNIX/LinuxNetwo…
The new Microsoft OS looks great, is easier than ever to upgrade to, it is even free.  So what's the catch?  If you don't change the privacy settings, Microsoft will, in accordance with the (EULA) you clicked okay to without reading, collect all the…
The viewer will learn how to simulate a series of coin tosses with the rand() function and learn how to make these “tosses” depend on a predetermined probability. Flipping Coins in Excel: Enter =RAND() into cell A2: Recalculate the random variable…
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question