Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Problem to access Generic handler in asp.net 4.0

Problem to access Generic handler in asp.net 4.0

Scheduled Pinned Locked Moved ASP.NET
csharpjavascriptasp-netdesignhelp
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    cocoonwls
    wrote on last edited by
    #1

    Hi all, Currently i am using C#.net 4.0 & JQuery to develop a web project. My problem is I cant invoke the .ashx by using autocomplete(jquery) function. I had done it before in C#.net 3.5 but everything is ok. below is the sample i done in 4.0: In UI :

    $("[id$='txtApplicant']").autocomplete("../../AutoSuggest.ashx");

    In Httphandler :

    public void ProcessRequest(HttpContext context)
    {
    HttpRequest Request = context.Request;
    HttpResponse Response = context.Response;

           // some code and logic here
    
           dtResult = getResult(cno,table,field,q);
           DataRow\[\] drs = dtResult.Select();
           foreach (DataRow dr in drs)
           {
               Response.Write(dr\["Result"\].ToString() + Environment.NewLine);  
           }
                        
        }
    

    Note: I was put httphandler file outside of the app_code folder (is the must to put in app_code folder?) and I din't register any httphandler in web.config Is something have to configure in web.config? Any tips or suggest are welcome Thanks in advance Cocoonwls

    C 1 Reply Last reply
    0
    • C cocoonwls

      Hi all, Currently i am using C#.net 4.0 & JQuery to develop a web project. My problem is I cant invoke the .ashx by using autocomplete(jquery) function. I had done it before in C#.net 3.5 but everything is ok. below is the sample i done in 4.0: In UI :

      $("[id$='txtApplicant']").autocomplete("../../AutoSuggest.ashx");

      In Httphandler :

      public void ProcessRequest(HttpContext context)
      {
      HttpRequest Request = context.Request;
      HttpResponse Response = context.Response;

             // some code and logic here
      
             dtResult = getResult(cno,table,field,q);
             DataRow\[\] drs = dtResult.Select();
             foreach (DataRow dr in drs)
             {
                 Response.Write(dr\["Result"\].ToString() + Environment.NewLine);  
             }
                          
          }
      

      Note: I was put httphandler file outside of the app_code folder (is the must to put in app_code folder?) and I din't register any httphandler in web.config Is something have to configure in web.config? Any tips or suggest are welcome Thanks in advance Cocoonwls

      C Offline
      C Offline
      cocoonwls
      wrote on last edited by
      #2

      I have get it work right now. Thanks for those who viewing my post. Thanks

      N 1 Reply Last reply
      0
      • C cocoonwls

        I have get it work right now. Thanks for those who viewing my post. Thanks

        N Offline
        N Offline
        Not Active
        wrote on last edited by
        #3

        This is a volunteer site. People will answer on their time, not yours. Don't be impatient and rude. If you need immediate help then call Microsoft support and pay


        No comment

        C 1 Reply Last reply
        0
        • N Not Active

          This is a volunteer site. People will answer on their time, not yours. Don't be impatient and rude. If you need immediate help then call Microsoft support and pay


          No comment

          C Offline
          C Offline
          cocoonwls
          wrote on last edited by
          #4

          Hi Mark, I don't understand what yours mean but for your information ,since i be a member of this volunteer site, i NEVER (you may view all of my message posted previously...but if you be impatient,you may skip this step )being rude and impatient for others. I am not sure that is any mistake I was made by my previous post then make you comment me like that...but anyway, thanks too because of viewing my question. p/s: I know if i pay for Microsoft, they will help me immediately. Thanks for your advice.

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups