File: HelloWorldHttpHandler.ashx
<%@ WebHandler Language="VB" Class="HelloWorldHandler" %>
imports System
imports System.Web
public Class HelloWorldHandler
Implements IHttpHandler
Sub ProcessRequest(context As HttpContext) Implements IHttpHandler.ProcessRequest
Dim Request As HttpRequest = context.Request
Dim Response As HttpResponse = context.Response
Response.Write("<html>")
Response.Write("<body>")
Response.Write(" <h1> Hello " + Request.QueryString("Name") + "</h1>")
Response.Write("</body>")
Response.Write("</html>")
End Sub
Public ReadOnly Property IsReusable As Boolean Implements IHttpHandler.IsReusable
Get
return true
End Get
End Property
End Class
|