.......Mainwindow.xaml...... .......Mainwindow.xam.cs...... using Microsoft.UI.Xaml; using Microsoft.UI.Xaml.Controls; using Microsoft.UI.Xaml.Controls.Primitives; using Microsoft.UI.Xaml.Data; using Microsoft.UI.Xaml.Input; using Microsoft.UI.Xaml.Media; using Microsoft.UI.Xaml.Navigation; using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Runtime.InteropServices.WindowsRuntime; using Windows.Foundation; using Windows.Foundation.Collections; // To learn more about WinUI, the WinUI project structure, // and more about our project templates, see: http://aka.ms/winui-project-info. namespace App4 { /// /// An empty window that can be used on its own or navigated to within a Frame. /// public sealed partial class MainWindow : Window { public MainWindow() { this.InitializeComponent(); } private void myButton_Click(object sender, RoutedEventArgs e) { myButton.Content = "Clicked"; } } } .......ResourceDictionary1.xaml...... M18,9.2c-0.2,0-0.4,0.2-0.5,0.5v5H6.4V3.4h5 c0.2,0,0.4-0.2,0.4-0.5c0-0.2-0.2-0.4-0.4-0.5H6C5.7,2.5,5.5,2.7,5.5,3V15c0,0.2,0.2,0.4,0.5,0.5H18c0.2,0,0.4-0.2,0.5-0.5V9.6 C18.5,9.4,18.3,9.2,18,9.2z M18.5,2.8c0-0.1-0.1-0.2-0.2-0.2c0,0-0.1,0-0.2,0H15c-0.2,0-0.4,0.2-0.5,0.5c0,0.2,0.2,0.4,0.5,0.5h2 l-5,5c-0.2,0.2-0.2,0.4,0,0.6c0,0,0,0,0,0c0.2,0.2,0.5,0.2,0.7,0l5-5v2c0,0.3,0.2,0.5,0.5,0.5c0.3,0,0.5-0.2,0.5-0.5V3 C18.5,2.9,18.5,2.8,18.5,2.8z .......App.xaml...... .......App.xaml.cs...... using Microsoft.UI.Xaml; using Microsoft.UI.Xaml.Controls; using Microsoft.UI.Xaml.Controls.Primitives; using Microsoft.UI.Xaml.Data; using Microsoft.UI.Xaml.Input; using Microsoft.UI.Xaml.Media; using Microsoft.UI.Xaml.Navigation; using Microsoft.UI.Xaml.Shapes; using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Runtime.InteropServices.WindowsRuntime; using Windows.ApplicationModel; using Windows.ApplicationModel.Activation; using Windows.Foundation; using Windows.Foundation.Collections; // To learn more about WinUI, the WinUI project structure, // and more about our project templates, see: http://aka.ms/winui-project-info. namespace App4 { /// /// Provides application-specific behavior to supplement the default Application class. /// public partial class App : Application { /// /// Initializes the singleton application object. This is the first line of authored code /// executed, and as such is the logical equivalent of main() or WinMain(). /// public App() { this.InitializeComponent(); } /// /// Invoked when the application is launched normally by the end user. Other entry points /// will be used such as when the application is launched to open a specific file. /// /// Details about the launch request and process. protected override void OnLaunched(Microsoft.UI.Xaml.LaunchActivatedEventArgs args) { m_window = new MainWindow(); m_window.Activate(); } private Window m_window; } }