This property allows you to set your own selected year in place of the default selected year, so that on start the year scroll field will immediately scroll to that specific year.

This property only works if TodayAsDefaultDay property is set to false and this property works in conjunction with DefaultDay & DefaultMonth.

The selected year must be within the range set by YearRangeMax and YearRangeMin.




AMADatePicker.ADP.DefaultYear = 1989; 


using UnityEngine;
using AMADatePicker;

public class DateViewer : MonoBehavior

// Get reference to an ADP instance through the inspector
[SerializeField] private ADP _ADPInstance;

// Setting default date as August 29, 1989
private void Start()
    _ADPInstance.TodayAsDefaultDay = false;

    _ADPInstance.DefaultMonth = 8;
    _ADPInstance.DefaultDay = 29;
    _ADPInstance.DefaultYear = 1989;

Leave a Reply

Your email address will not be published. Required fields are marked *