Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6732699
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:40:53+00:00 2026-05-26T10:40:53+00:00

What made me curious is that the generic handler works just fine when I’m

  • 0

What made me curious is that the generic handler works just fine when I’m running the Web App in a Visual Studio ASP.NET Development Server. When I change the config to run it directly from IIS the handler just dies.

It’s an image handler, it writes back an array of bytes to be rendered in an Image object. As I said, it works fine in VS Development Server, but fails on IIS. It doesn’t even get called…

The error I get when I’m trying to call it directly is this:

Parser Error Description: An error occurred during the parsing of a
resource required to service this request. Please review the following
specific parse error details and modify your source file
appropriately. Parser Error Message: Could not create type
‘YourImageHandler’. Source Error: Line 1: <%@ WebHandler
Language=”C#” CodeBehind=”YourImagehandler.ashx.cs”
Class=”YourImageHandler” %>

Handler on web.config:

<system.web>
    <httpHandlers>
      <add verb="*" path="*.ashx"  type="YourImageHandler"/>
    </httpHandlers>
</system.web> 

The Generic Handler is in the same assembly of the Web Project, and the whole thing is running on IIS 7.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T10:40:54+00:00Added an answer on May 26, 2026 at 10:40 am

    If you are using IIS 7 in pipeline mode then the handler definition must be in <System.webServer>
    Like this:

    <system.webServer>
    <handlers>
        <add name="YourImageHandlerName" path="*.ashx" verb="*" type="YourImageHandler" />
    </handlers>
    </system.webServer>
    

    Check here: http://blogs.msdn.com/b/tmarq/archive/2007/08/30/iis-7-0-asp-net-pipelines-modules-handlers-and-preconditions.aspx

    IIS 7.0 has two pipeline modes: integrated and classic. The latter is
    sometimes referred to as ISAPI mode.

    Integrated mode allows both managed and native modules to register for
    events in the IIS pipeline. This enables many new scenarios, such as
    applying ASP.NET forms authentication to non-asp.net requests (static
    files, classic ASP files, etc).

    Classic mode is identical to IIS 6.0. In classic mode, the ASP.NET
    pipeline (BeginRequest, AuthenticateRequest,…, EndRequest) runs
    entirely within the IIS pipeline’s EXECUTE_REQUEST_HANDLER event.
    Think of ASP.NET in classic mode as a pipeline within a pipeline.

    The other option is to run your site in “classic” mode, in classic mode IIS 7 works like IIS 6 and has the same behaviour (for what matters here) as your Cassini web server.

    Hope that help.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Just curious if there was anything that made a partial view different from a
I made it work. However, there is a curious detail I noticed. My Web
Just curious to know that if my PC is infected with a Trojan or
I have a web app that is using ActiveResource to talk to another server
I'm curious why it's made exactly like that ? If i call this through
I am stress testing my application using JMeter my app is made an Asp.net
I'm curious about the performance enhancements that have been made for FSharpFunc<_> . Is
I have made something just like this using php and mysql. Just curious to
Made this nice little loop for hiding and showing div's, works as a charm
I made a discovery some time back. Just follow these steps: Create a .doc/.xls/.ppt

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.