ModernXamarinCalendar 1.0.4

Modern Xamarin.Forms Calendar that is both interactive and also fits well with only two weeks showing.

Install-Package ModernXamarinCalendar -Version 1.0.4
dotnet add package ModernXamarinCalendar --version 1.0.4
<PackageReference Include="ModernXamarinCalendar" Version="1.0.4" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add ModernXamarinCalendar --version 1.0.4
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

GitHub

Setup

Step 1

Install the Nuget Package using Nuget Package Manager or in the Package Manager Console run command:

   Install-Package ModernXamarinCalendar -Version 1.0.4
Step 2

In the XAML content page where you would like the Calendar to go (such as MainPage.xaml), write within the Content Page Tag

   xmlns:control="clr-namespace:ModernXamarinCalendar;assembly=ModernXamarinCalendar"
Step 3

Within your layout in the same XAML Page, place

    <control:WeekControl x:Name="CalendarWeekControl"
                         HorizontalOptions="CenterAndExpand"
                         BackgroundColor="SteelBlue"/>
Step 4

In the c# code for your content page (such as MainPage.xaml.cs)

     public void SelectedDateChanged(object sender, EventArgs e)
     {
         var calendar = sender as WeekControl;

         // insert code here that you want to use the date selected for...

         // control.SelectedDate returns a DateTime for the selected day.

         Debug.WriteLine(calendar.SelectedDate.ToString());
     }
Step 5

In the same c# file, write within the constructor

   CalendarWeekControl.SelectedDateChanged += SelectedDateChanged;  
Step 6

Download images from

GitHub - Images - Download this folder for icons for the nuget package

and install them in your project

Options

Show labels for the days of the week (SUN MON TUE WED THU FRI SAT)

In the XAML page, set this property for the WeekControl:

   ShowDayName="True"

or in the C# code:

   CalendarWeekControl.ShowDayName = true;

(The default value for ShowDayName is false, so not specifying it means the
days will not show up).

Change the color of the calendar and its text

In the XAML page, set this property for the WeekControl:

   ForegroundColor="White"

(The default value for ForegroundColor is Black).

GitHub

Setup

Step 1

Install the Nuget Package using Nuget Package Manager or in the Package Manager Console run command:

   Install-Package ModernXamarinCalendar -Version 1.0.4
Step 2

In the XAML content page where you would like the Calendar to go (such as MainPage.xaml), write within the Content Page Tag

   xmlns:control="clr-namespace:ModernXamarinCalendar;assembly=ModernXamarinCalendar"
Step 3

Within your layout in the same XAML Page, place

    <control:WeekControl x:Name="CalendarWeekControl"
                         HorizontalOptions="CenterAndExpand"
                         BackgroundColor="SteelBlue"/>
Step 4

In the c# code for your content page (such as MainPage.xaml.cs)

     public void SelectedDateChanged(object sender, EventArgs e)
     {
         var calendar = sender as WeekControl;

         // insert code here that you want to use the date selected for...

         // control.SelectedDate returns a DateTime for the selected day.

         Debug.WriteLine(calendar.SelectedDate.ToString());
     }
Step 5

In the same c# file, write within the constructor

   CalendarWeekControl.SelectedDateChanged += SelectedDateChanged;  
Step 6

Download images from

GitHub - Images - Download this folder for icons for the nuget package

and install them in your project

Options

Show labels for the days of the week (SUN MON TUE WED THU FRI SAT)

In the XAML page, set this property for the WeekControl:

   ShowDayName="True"

or in the C# code:

   CalendarWeekControl.ShowDayName = true;

(The default value for ShowDayName is false, so not specifying it means the
days will not show up).

Change the color of the calendar and its text

In the XAML page, set this property for the WeekControl:

   ForegroundColor="White"

(The default value for ForegroundColor is Black).

Release Notes

Re-center Date Selection

Dependencies

This package has no dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version History

Version Downloads Last updated
1.0.4 283 1/11/2020
1.0.3 156 1/6/2020
1.0.2 234 5/28/2019
1.0.1 202 5/28/2019
1.0.0 201 5/25/2019