Issue
Is there a library or a way to add events to a Calendar, in the style of google calendar? I have searched but have only found to select the date, but not to assign an event or task to a specific date in the Calendar using Netbeans for Desktop App.
Solution
The name of the standard Calendar
class (java.util.Calendar
) is misleading - the class is not a calendar as we are used to, it does not store appointments, events or that like - it is more like an instant in time.
It is normally used to work with the different date/time fields like Hour, Day, Month, ...
For details, see the documentation:
The Calendar class is an abstract class that provides methods for converting between a specific instant in time and a set of calendar fields such as YEAR, MONTH, DAY_OF_MONTH, HOUR, and so on, and for manipulating the calendar fields, such as getting the date of the next week. ...
Answered By - user13510609
Answer Checked By - Terry (JavaFixing Volunteer)