Export (0) Print
Expand All

WebRequest.Abort Method

Cancels an asynchronous request to an Internet resource.

[Visual Basic]
Public Overridable Sub Abort()
[C#]
public virtual void Abort();
[C++]
public: virtual void Abort();
[JScript]
public function Abort();

Exceptions

Exception Type Condition
NotSupportedException Any attempt is made to access the method, when the method is not overridden in a descendant class.

Remarks

The Abort method cancels asynchronous requests to Internet resources started with the BeginGetResponse method.

Note   The WebRequest class is an abstract (MustInherit in Visual Basic) class. The actual behavior of WebRequest instances at run time is determined by the descendant class returned by the WebRequest.Create method. For more information about default values and exceptions, see the documentation for the descendant classes, such as HttpWebRequest and FileWebRequest.

Requirements

Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, .NET Compact Framework, Common Language Infrastructure (CLI) Standard

See Also

WebRequest Class | WebRequest Members | System.Net Namespace

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft