TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Meghana B
NA
50
10.3k
Background colour not changing in wpf help me
Nov 3 2020 2:30 AM
Hello Team,
Background colour not changing in wpf help me
<
Window
x:Class
=
"WpfResources.MainWindow"
xmlns
=
"http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x
=
"http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d
=
"http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc
=
"http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local
=
"clr-namespace:WpfResources"
mc:Ignorable
=
"d"
Title
=
"MainWindow"
Height
=
"450"
Width
=
"800"
>
<
Window.Resources
>
<
SolidColorBrush
Color
=
"Red"
x:Key
=
"ButtonColorRed"
>
</
SolidColorBrush
>
</
Window.Resources
>
<
Grid
>
<
Button
Width
=
"200"
Height
=
"100"
Margin
=
"47,68,553,266"
Background
=
"{StaticResource ButtonColorRed}"
>
</
Button
>
<
Button
Width
=
"200"
Height
=
"100"
Margin
=
"332,90,268,244"
Background
=
"{StaticResource ButtonColorRed}"
>
<
Button.Style
>
<
Style
TargetType
=
"Button"
>
<
Setter
Property
=
"Background"
Value
=
"Blue"
>
</
Setter
>
</
Style
>
</
Button.Style
>
</
Button
>
</
Grid
>
</
Window
>
Thanks in Advanace
Meghana.
Reply
Answers (
2
)
Tutorial how to insert and update easily directly in DataGrid WPF
How to host windows forms control in WPF?