Click here to Skip to main content
15,898,036 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
How to upload and display image in gridview without using database in asp.net?

I want to display an image in gridview by using file upload control but the image is not store in database.Just the image is displayed instantly on grid view screen.

What I have tried:

I want to display an image in gridview by using file upload control but the image is not store in database.Just the image is displayed instantly on grid view screen.
Posted
Updated 13-May-18 1:36am
Comments
Ali Javani 12-May-18 5:02am    
Hi can you explain more and give m more information ?

1 solution

You do not need a database to upload and fetch the image. You can upload the image anywhere, like a file system, now which ASP.NET you are using is going to help us trim the search down a bit, but general ASP.NET File Upload article can be read here, File Upload with ASP.NET[^].

You can store the image URL, for the location where the image is stored and then use that to create a Uri mapping for the GridView to render an image.

Dynamically setting image url in Gridview | The ASP.NET Forums[^]
how to set image url in gridview[^]
 
Share this answer
 

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



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900