Click here to Skip to main content
12,758,051 members (32,930 online)
Rate this:
Please Sign up or sign in to vote.
See more: MVC2
Download A excel from Local Path in MVC2
when Clicking on link Text it will open .
can you please suggest any link..
i try like below but not working

string Path = @"~\Content\templates\SAT Door Width 062012.xls";
            string contentType = "application/ms-excel";
            HttpContext.Response.Buffer = true;
           HttpContext.Response.AddHeader("content-disposition",                         "attachment; filename=" + fileName);
            HttpContext.Response.ContentType = contentType;
Posted 18-Jan-13 2:11am
Updated 20-Jan-13 20:24pm
richcb 18-Jan-13 11:24am
This is not a question.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

    Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.170217.1 | Last Updated 21 Jan 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100