İçeriğe atla
Ekim 31, 2011 / sukruerdem

ASHX dosya’da Session Tanımlama

Bir ASHX dosya’da Session tanımlamak için öncelikle;

public class ClassName : IHttpHandler,IRequiresSessionState
public void ProcessRequest(HttpContext context){

string name = “this is the string”;

context.Session["session"]=name;

}

 

Bu session igili projede herhangi bir class’ta kullanılabilir.

 

Yorum yapın

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Değiştir )

Twitter picture

You are commenting using your Twitter account. Log Out / Değiştir )

Facebook photo

You are commenting using your Facebook account. Log Out / Değiştir )

Connecting to %s

Follow

Get every new post delivered to your Inbox.