我有一个ListBox
用xaml写的:
<ListBox Margin="0" x:Name="ListBox_Main" Grid.Row="1" VerticalAlignment="Top" FontSize="24" SelectionChanged="ListBox_Main_SelectionChanged" Foreground="Black">
<ListBoxItem Content="Item 1" Background="#19000000" />
<ListBoxItem Content="Item 2" Background="#19000000" />
<ListBoxItem Content="Item 3" Background="#19000000" />
<ListBoxItem Content="Item 4" Background="#19000000"/>
<ListBoxItem Content="Item 5" Background="#19000000"/>
</ListBox>
我们可以看到背景颜色是#19000000
,我们可以在 C# 中更改颜色吗?