XAML Views
Learn how to work with code-behind files in a .NET MAUI application.
We'll cover the following
XAML files in MAUI rarely work on their own. Typically, each of these files has a code-behind file attached to it. The code-behind file contains a standard C# class. But the XAML file can interoperate with it. The XAML file is interpreted by the compiler as a part of the same class. So, the XAML file and the code-behind associated with it are typically interpreted as two parts of the same partial class.
To demonstrate how code-behind interoperates with XAML, we have the following MAUI project inside an interactive code widget.
Get hands-on with 1200+ tech skills courses.