tags:

views:

645

answers:

3

My httphandler does not work in IIS7 (virutal directory), but using cassini it works.

It used to work on my windows xp IIS also.

What could be the cause of this?

I am getting a 404 not found error when trying to access the httphandler's page.

A: 

Check that the Network Service (or whatever the identiy underwhich its application pool runs) has read access to the .ashx file.

AnthonyWJones
+4  A: 

IIS7 depends on the registration for HttpHandlers to be in a different location than usual. There is a section in system.web/webserver/handlers where you should be able to register your HttpHandler, as opposed to the standard system.web/httpHandlers

Hope that helps

LorenVS
This is only true when your application pool is running under "Integrated" mode.
David
A: 

I have the same problem. I have an axd file registered in the web.config file. The site renders fine in all conditions, the only thing that doesn't work is the axd reference.

Using the asp.net development server (cassini) everything works perfectly.

   h t t p : / / localhost:5059    <-- works fine

But if I use the IIS instance on the machine, and a properly created virtual directory on my machine...

   h t t p : / / localhost/appName    <-- Doesn't Work.

Site renders but calls to the axf fail (404). So it isn't an improperly registered handler, a permissions issue, or a mis-spelled URL.

Additionally, if I deploy it to a server under a domain name, as a virtual directory, it works there too.

   h t t p : / / www.adomainname.com/appname    <-- works fine

The only issue is developing using IIS rather than Cassini.

pblanton