Reputation: 105
I have a database where i have the physical path where image of a person is stored . now i want a code by which I can display the image of that person in a aspx window.
as I am new to asp.net & C# can somebody provide me the full code of aspx page and the C# code behind it?
Upvotes: 0
Views: 636
Reputation: 12419
Here's a good example on how to connect to a database and display the data in ASP.NET: How to: Bind to Data in a Templated Control on MSDN.
Also there a lots of great tutorials on the ASP.NET "official" site.
Update: Alright, now we got something to work with. Do you know if your HttpHandler is throwing any exceptions? Place a breakpoint in the HttpHandler code and hit F5 (Visual Studio) to launch the site in debug bug mode. Maybe you're not passing an image ID to the handler? Try and hardcode an ID in the .aspx for an image you know that exists in the database.
See if you can update your question and format the code: Just select the code sample and click the "code" button in the editor. It will indent the text and apply nice formatting, making it easier to read. Also include your .aspx page so we can see what's going on there.
Upvotes: 2