In this article

The .NET Portability Analyzer

07/26/2017

2 minutes to read

Contributors

In this article

Want to make your libraries multi-platform? Want to see how much work is required to make your application compatible with other .NET implementations and profiles, including .NET Core, .NET Standard, UWP, and Xamarin for iOS, Android, and Mac? The .NET Portability Analyzer is a tool that provides you with a detailed report on how flexible your program is across .NET implementations by analyzing assemblies. The Portability Analyzer is offered as a Visual Studio Extension and as a console app.

New targets

.NET Core: Has a modular design, employs side-by-side, and targets cross-platform scenarios. Side-by-side allows you to adopt new .NET Core versions without breaking other apps.

ASP.NET Core: is a modern web-framework built on .NET Core thus giving developers the same benefits.

Universal Windows Platform: Improve performance of your Windows Store apps that run on x64 and ARM machines by using .NET Native’s static compilation.

.NET Core + Platform Extensions: Includes the .NET Core APIs in addition to other APIs in the .NET ecosystem such as WCF, ASP.NET Core, FSharp, and Azure.

.NET Standard + Platform Extensions: Includes the .NET Standard APIs in addition to other .NET ecosystem such as WCF, ASP.NET Core, FSharp, and Azure.

How to use Portability Analyzer

To begin using the .NET Portability Analyzer, you first need to download and install the extension from the Visual Studio Marketplace. It works on Visual Studio 2015 and Visual Studio 2017. You can configure it in Visual Studio via Analyze > Portability Analyzer Settings and select your Target Platforms.

After running the analysis, you will see your .NET Portability Report. Only types that are unsupported by a target platform appear in the list and you can review recommendations in the Messages tab in the Error List. You can also jump to problem areas directly from the Messages tab.

Don’t want to use Visual Studio? You can also use the Portability Analyzer from the command prompt. Just download the API Portability Analyzer.

Type the following command to analyze the current directory: \...\ApiPort.exe analyze -f .