WebRequest.Abort Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Aborts the request.
public:
abstract void Abort();
public:
virtual void Abort();
public abstract void Abort ();
public virtual void Abort ();
abstract member Abort : unit -> unit
abstract member Abort : unit -> unit
override this.Abort : unit -> unit
Public MustOverride Sub Abort ()
Public Overridable Sub Abort ()
Exceptions
Any attempt is made to access the method, when the method is not overridden in a descendant class.
Remarks
Caution
WebRequest
, HttpWebRequest
, ServicePoint
, and WebClient
are obsolete, and you shouldn't use them for new development. Use HttpClient instead.
The Abort method cancels asynchronous requests to Internet resources started with the BeginGetResponse method.
Note
The WebRequest class is an abstract
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.
Applies to
Povratne informacije
https://aka.ms/ContentUserFeedback.
Stiže uskoro: Tijekom 2024. postupno ćemo ukinuti servis Problemi sa servisom GitHub kao mehanizam za povratne informacije za sadržaj i zamijeniti ga novim sustavom za povratne informacije. Dodatne informacije potražite u članku:Pošaljite i pogledajte povratne informacije za