Showing posts with label Http Handlers. Show all posts
Showing posts with label Http Handlers. Show all posts

Wednesday, September 19, 2012

Accessing session Value in Http Handlers and from Http Handlers

In this post i will explain how to access session Value in Http Handlers and from session value from Http Handlers.

In the previous post Dynamic Thumbnail Images using Http Handlers in asp.net C# explained how to show images using Http Handlers.

To access session value in Http Handler use following code

Ex :

In the code behind


         Session["imgID"] = "2";

Dynamic Thumbnail Images using Http Handlers in asp.net C#

In this post I will show how to display ThumbNail Images Dynamically Using Httphandlers in asp.net and C#. In this post i will Show How to Access Session Values in HttpHandler

Add new generic handler and name it as you like In my case ThumbNail.ashx and the code for this handler can be seen below.

Out Put :



Http Handler (*.ashx) :