Socket.UseOnlyOverlappedIO Property

Definition

Caution

UseOnlyOverlappedIO has been deprecated and is not supported.

Gets or sets a value that specifies whether the socket should only use Overlapped I/O mode. On .NET 5+ (including .NET Core versions), the value is always false.

C#
public bool UseOnlyOverlappedIO { get; set; }
C#
[System.Obsolete("UseOnlyOverlappedIO has been deprecated and is not supported.")]
public bool UseOnlyOverlappedIO { get; set; }

Property Value

true on .NET Framework if the Socket uses only overlapped I/O; otherwise, false. The default is false.

Attributes

Exceptions

The socket has been bound to a completion port.

Remarks

.NET Framework only: Set this property to true for a Socket you intend to call DuplicateAndClose on. Otherwise, the Framework may assign a completion port to the socket, which would prohibit the use of DuplicateAndClose.

On .NET 5+ (include .NET Core) versions, the value of this property is always false, and you cannot change its value.

Applies to

Product Versions (Obsolete)
.NET Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5 (6, 7, 8, 9)
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1