Can i use session values inside a WebMethod?
I\'ve tried using System.Web.Services.WebMethod(EnableSession = true) but i can\'t access Session parameter
System.Web.Services.WebMethod(EnableSession = true)
You can use:
HttpContext.Current.Session
But it will be null unless you also specify EnableSession=true:
null
EnableSession=true
[System.Web.Services.WebMethod(EnableSession = true)] public static String checaItem(String id) { return "zeta"; }