Generic handlers are the .NET components that implement the System.Web.IHttpHandler interface. Any class that implements the IHttpHandler interface can act as a target for the incoming HTTP requests.
Questions tagged [generic-handler]
161 questions
3
votes
1 answer
second parameter interfering with generic handler
My problem is this. When I just have a single parameter to search by, my image control works, when I try and pass a second parameter through, the image control does not work.
I am using a generic handler as the image.URL, as I want to be able to…

Bigtingz92
- 129
- 1
- 15
3
votes
3 answers
Generic handler not returning values
Handler is not returning image. If I remove conditional statement, handler is returning image. This is my code
public void ProcessRequest(HttpContext context)
{
string sid = "JUN15MBACHN001";
SqlConnection connection = new…

joseph amalanathan
- 31
- 3
3
votes
1 answer
Unit Testing Generic Handlers
How can i test return value of "ProcessRequest" method in a generic handler with unit Test?
public class Handler1 : IHttpHandler
{
public void ProcessRequest(HttpContext context)
{
context.Response.ContentType = "text/plain";
…

sadeghhp
- 621
- 14
- 28
3
votes
1 answer
Form submit cancels jQuery ajax call
I have a Generic Handler (DownloadHandler.cs) which serves as both generating a pdf and downloading a pdf. When generating I use a jQuery ajax call and when downloading I use a form element which is submitted. The problem is that the form element…

Dumpen
- 1,622
- 6
- 22
- 36
2
votes
1 answer
Set Extension For Handler.ashx
I have a generic handler Image.ashx that crops/resizes images on the fly by reading information from the querystring like Image.ashx?filename=foo.jpg&maxwidth=200&maxheight=300.
Is there a way that I can change the extension of this handler to .jpg?…

Greg
- 8,574
- 21
- 67
- 109
2
votes
2 answers
ASP.NET Routing. How can i use Routing in a Generic Handler?
I tried to use ASP.Net's in the following generic handler, but i get this error at Page.RouteData
Reference to a non-shared member requires an object reference
What i am doing wrong?
<%@ WebHandler Language="VB" Class="MainHandler" %>
Imports…

OrElse
- 9,709
- 39
- 140
- 253
2
votes
0 answers
Task Scheduler starts .EXE Program which opens Web Page which connects to database, results in "Login Failed for NT Authority/Anonymous"
I have a Windows Task Scheduler task that starts a .NET .exe application.
(As you dive in, keep in mind that all of this is being done to avoid a strict, unbendable CORS policy at my company)
This application "shells out" to the OS to open Chrome to…

KWallace
- 624
- 7
- 15
2
votes
1 answer
FileUploadHandler.ashx taking 99 seconds to process every continuous 5th Request
I'm having a FileUploadHandler.ashx in a web service to upload files to server in win forms application.
Even if FileUploadHandler made async / sync (tried both), it's taking time for every 5th Request...
I've a large no.of files, looping them to…

Abdul Rahman
- 115
- 1
- 9
2
votes
1 answer
jQuery Bootgrid sorting, pagination and search functionality not working
I have a jQuery bootgrid implemented into my ASP.Net application which is filled using a Generic Handler.
I fill the bootgrid using the Generic Handler as follows:
$(function () {
var grid = $("#grid").bootgrid({
ajax: true,
…

Barry Michael Doyle
- 9,333
- 30
- 83
- 143
2
votes
1 answer
How to Generate a kml through a handler while getting the points from sqlserver into a asp.net
I am new in asp.net and I am not understanding how to generate a kml file using an Generic Handler file. I am able to create an handler file and confused where and how to connect database and get the latitude and longitude and define it in kml and…
user5596299
2
votes
2 answers
Generic handler file download does not start
I'm trying to start downloading files from server, now just with some hardcoded values for files which exists but for some reason the download does not start and no error is thrown.
This is the code I have:
public void ProcessRequest(HttpContext…

Laziale
- 7,965
- 46
- 146
- 262
2
votes
0 answers
Uploading images with asp.net generic handler
I am trying to upload multiple files using the following code.
HTML & JQuery
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="FileUpload.WebForm1" %>

Joshua
- 2,275
- 7
- 41
- 57
2
votes
1 answer
MVC3 generic handler (.ashx) for Images resizing (Need clean URL)
I have a generic handler (.ashx) in asp.net mvc3 web application. I use it to resize and cache images. but my Url is not clean (http://www.example.com/Thumb.ashx?img=someimage.jpg) I want to make it clean like…

aadi1295
- 982
- 3
- 19
- 47
2
votes
1 answer
ASP.NET Generic Handler not getting called after .NET 3.5 to .NET 4.0 upgrade
This old title describes the visible issue, but the new title describes the root cause issue a little better. I'm still not sure why the ASHX isn't getting called, so I'm still looking for an answer. I have a workaround for now by hard coding the…

JustBeingHelpful
- 18,332
- 38
- 160
- 245
2
votes
1 answer
Interfacing with a Generic Handler
I have this generic handler in C#:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace RequestResponse
{
public class Handler : IHttpHandler
{
public void ProcessRequest(HttpContext…

Matthew
- 4,477
- 21
- 70
- 93