- Mastering Visual Studio 2017
- Kunal Chowdhury
- 46字
- 2025-04-04 18:47:06
Property element syntax
The properties can also be defined as an element when you cannot assign the value within the quotes. This generally starts with <element.PropertyName> and ends with </element.PropertyName>. The following example shows you how to write the Background property as an element to the Button:
<Button> <Button.Background> <SolidColorBrush Color="Red" /> </Button.Background> </Button>