Neekko33

Neekko33

Learning .NET now
playstation

Asynchronous Operations in "Illustrated Tutorial of C#"

When reading the 21.9 Other Asynchronous Programming Patterns in the fifth edition of the book "C# Illustrated Tutorial," an error message was encountered when using the BeginInvoke function according to the example code:

Unhandled exception. System.PlatformNotSupportedException: Operation is not supported on this platform.

After consulting the documentation, starting from .NET Framework 4, the Task Parallel Library provides a new model for asynchronous and parallel programming, namely the Task-based Asynchronous Pattern (TAP). On the latest .NET platform, the BeginInvoke function and EndInvoke function are no longer supported. This is noted for reference.

References:

  1. Migrating Delegate.BeginInvoke Calls for .NET Core
Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.