Hi Robbes!I think I done it correctly but I have a little question,like
this code is inside a usercontol file
function uploadComplete(sender, args) {
filename = args.get_fileName(); //it gets file name to be uploaded(toolkit functions)
PageMethods.GetImageDimension(function (response) {
$dimension = eval(response); //response is in json format
$width = $dimension.width;
$height = $dimension.height;
showlightbox();
});
}
and this code is inside a c# code behind file:
[WebMethod(EnableSession = true)]
public static string GetImageDimension()
{
return HttpContext.Current.Session["ImageDimension"].ToString();
}
Then My question is I am need a generic handler to perform that ?
if yes how can I access this function inside a class that that I called member using generic handler.
public MemberInfo(int Id)
{
SqlDataReader dr = SqlHelper.ExecuteReader(SqlHelper.GetConnection(), "GetUserByUserId", Id);
if (dr.HasRows)
{
dr.Read();
UserId = Convert.ToInt32(dr["UserId"]);
Name = Convert.ToString(dr["Name"]);
Image = Convert.ToString(dr["Image"]);
CompanyName = Convert.ToString(dr["CompanyName"]);
Description = Convert.ToString(dr["Description"]);
Experience = Convert.ToString(dr["Experience"]);
Address = Convert.ToString(dr["Address"]);
Website = Convert.ToString(dr["Website"]);
RegistrationType = Convert.ToInt32(dr["RegistrationType"]);
PhoneNo = Convert.ToString(dr["PhoneNo"]);
UserName = Convert.ToString(dr["UserName"]);
Password = Convert.ToString(dr["Password"]);
UserTypeId = Convert.ToInt32(dr["UserTypeId"]);
}
}