0

I get this error using c# handlers (.ashx) :

ProviderGrid.js:23 Uncaught ReferenceError: Handler is not defined

Here it's my handler file :

<%@ WebHandler Language="C#" Class="dashVidence.Handler" %>

using System;
using System.Web;

namespace dashVidence
{

    public class Handler : IHttpHandler
    {
//ReturnProvider contain a method returning string datas
        ReturnProvider rp = new ReturnProvider();
        public void ProcessRequest(HttpContext context)
        {

        }

        public bool IsReusable
        {
            get
            {
                return false;
            }
        }

        public string provider()
        {
            return rp.getProvidersList();
        }

    }
} 

The handler file is referenced in the aspx file

Brandon
  • 68,708
  • 30
  • 194
  • 223

1 Answers1

-1

Please add debugger; to this line.

 $(function () {
>         debugger;   <------------------HERE
>         $('#feedbackform').submit(function () {

now in browser right click inspect element and go to the console tab. if you do not hit this line onload turn

debugging on in your web.configuration.

hit submit. if you hit the line just go through it line by line and the offending line will throw a error.

if it just throws a error like the image below. Sorry not enough rep points to post image directly. :(

http://postimg.org/image/5ke0jd6xv/

then it is the line above other wise check out the stack.

Hope this helps

Quoting my self is amazing :)

though what you do is when the error fails insert the debugger on the level above it. Mind you this is a javascript error