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
Yannick Bersin
NA
3
2.6k
[Beginner] How to change DatePicker inside button margin?
Sep 30 2015 11:38 AM
Hello,
I did not find howI could solve this. I would like to change DatePicker inside button margin for all DatePicker without having to rewrite the template.
I have found how I can do it on one DatePicker by putting this :
<DatePicker>
<DatePicker.Resources>
<Style TargetType="{x:Type Button}">
<Setter Property="Margin" Value="3,0,1,0" />
</Style>
</DatePicker.Resources>
</DatePicker>
But I would like to avoid doing this on all DatePciker controls on my application. I would like to do it on my general style file.
With Snoop, I had a look at the control and I noticed the Button name is PART_Button and the default margin is 3,0,3,0. I would like to set it to 3,0,1,0.
I don't want to affect all buttons, just the DatePicker inside button.
If someone could help me on this, I would appreciate
Yannick
Reply
Answers (
2
)
Bing Map WPF Control and ESRI Shapefile
Dynamic Chart generation in WPF