Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# ASP.NET SQL
How to download files using a gridview in asp.net. How to give option in grid view and download particular file/ image.
Posted 29-Apr-12 23:20pm
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Please refer following links:
 
How to export GridView to Excel, render cells, add WordArt, and fill a custom template[^]
http://mattberseth.com/blog/2007/04/export_gridview_to_excel_1.html[^]
CodeProject Frequently Asked Questions Series 1: The ASP.NET GridView[^]
Downloading files like pdfs should be easy if they are attached to the GridView.
The browser should allow you to do that.
 
This will give you some more help, have a look:
Downloading files using grid view in asp.net[^]
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Hi,
 
add link button in gridview and set download path to commandargument of linkbutton using Eval and finally write download code on link button Click
 
Best Luck
  Permalink  

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

  Print Answers RSS
0 Maciej Los 295
1 OriginalGriff 278
2 Nguyen.H.H.Dang 230
3 Peter Leow 195
4 arvind mepani 187


Advertise | Privacy | Mobile
Web01 | 2.8.140709.1 | Last Updated 30 Apr 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid