我正在寻找Xamarin Form PCL的日历。经过几个小时的研究,我可以使用 XAMForms.Controls.Calender 开发一个Calander,但外观和感觉不一样。
答案 0 :(得分:1)
根据需要使用syncfusion xamarin Calendar Control和Customize
参考https://www.syncfusion.com/products/xamarin/calendar
和https://help.syncfusion.com/xamarin/sfcalendar/getting-started
您可以在syncfusion日历控件中自定义日历的每个单元格
答案 1 :(得分:1)
在GitHub上有一些插件
new Calendar
{
BorderColor = Color.Gay,
BorderWidth = 3,
BackgroundColor = Color.Gay,
StartDay = DayOfWeek.Sunday,
StartDate = DateTime.Now
}
public class SampleCalendarPage : ContentPage
{
CalendarView _calendarView;
StackLayout _stacker;
public SampleCalendarPage ()
{
Title = "Calendar Sample";
_stacker = new StackLayout ();
Content = _stacker;
_calendarView = new CalendarView() {
VerticalOptions = LayoutOptions.Start,
HorizontalOptions = LayoutOptions.CenterAndExpand
};
_stacker.Children.Add (_calendarView);
_calendarView.DateSelected += (object sender, DateTime e) => {
_stacker.Children.Add(new Label()
{
Text = "Date Was Selected" + e.ToString("d"),
VerticalOptions = LayoutOptions.Start,
HorizontalOptions = LayoutOptions.CenterAndExpand,
});
};
}
}
答案 2 :(得分:0)
我一直在使用的选项是ComponentOne日历。这对日历的时段具有模板支持,因此您可以创建日期单元格所需的任何外观。但它不是免费的。