public static ApplicationTheme ApplicationTheme {get; set;}
Public Shared Property ApplicationTheme As ApplicationTheme
public static ApplicationTheme ApplicationTheme {get; set;}
Public Shared Property ApplicationTheme As ApplicationTheme
//Gets the application's theme var theme = FrameworkApplication.ApplicationTheme; //ApplicationTheme enumeration if (FrameworkApplication.ApplicationTheme == ApplicationTheme.Dark) { //Dark theme } if (FrameworkApplication.ApplicationTheme == ApplicationTheme.HighContrast) { //High Contrast } if (FrameworkApplication.ApplicationTheme == ApplicationTheme.Default) { //Light/Default theme }
Target Platforms: Windows 11, Windows 10