c# - Setting a static datetime in WPF/xaml -
i'm trying blackout dates in datetime picker control starting day after today till datetime max value.
the below code:
<calendar.blackoutdates> <calendardaterange start="{x:static system:datetime.today}" end="{x:static system:datetime.maxvalue}" /> </calendar.blackoutdates>
as see, above code blackout dates starting today, want start date tomorrow. question is, how can set this:
start="{x:static system:datetime.today.adddays(1)}"
could please help?
you can create own static property this.
public static class datetimehelper { public static datetime tomorrow { { return datetime.today.adddays(1); } } }
.
<calendardaterange start="{x:static app:datetimehelper.tomorrow}"…
Comments
Post a Comment