WinForm:
private void button1_Click(object sender, EventArgs e)
{
button2.BackColor = Color.Red;
}
WPF:
private void button1_Click(object sender, RoutedEventArgs e)
{
button2.Background = Brushes.Blue;
}
More Related Contents:
- How to hide close button in WPF window?
- How to programmatically click a button in WPF?
- Image in WPF Button not Visible at Runtime
- Add parameter to Button click event
- Passing data between WPF forms
- Programmatically changing button icon in WPF
- Dynamically add multiple buttons to wpf window?
- How to set background of a datagrid cell during AutoGeneratingColumn event depending on its value?
- Using a Progress bar and a click counter
- WPF Shaped Button – Visaul Studio/Blend
- How to include external font in WPF application without installing it
- Prevent using Dispatcher.Invoke in WPF code
- .NET Memory issues loading ~40 images, memory not reclaimed, potentially due to LOH fragmentation
- page.DataContext not inherited from parent Frame?
- How do I exit a WPF application programmatically?
- Datagrid binding in WPF
- Open default mail client along with a attachment
- Static binding doesn’t update when resource changes
- How do you disable Aero Snap in an application?
- WPF DataBinding not updating?
- How can I simulate a mouse click at a certain position on the screen?
- How to add buttons dynamically to my form?
- Restart application using C#
- Convert System.Windows.Media.ImageSource to System.Drawing.Bitmap
- How can I open Windows Explorer to a certain directory from within a WPF app?
- How to deactivate “right click” on WPF Webbrowser Control?
- Binding Commands to Events?
- Is it possible to let my c# wpf program know if the user has a touchscreen or not?
- Parsing SVG “path” elements with C# – are there libraries out there to do this? [closed]
- What is the difference between Property and Dependency Property