Ionic Native calendar creates birthday event instead of regular event

Hey there,

(this is a Android device issue, any android platform any device)

Whenever I try to use createEvent or createEventWithOptions (the silent way of adding an event to a calendar), this does indeed create a event.
However the event that is created is a birthday event with a title, and nothing more. Which apparently also gets automatically removed after a few seconds from the calendar. So in order to see what’s going on I quickly have to switch to my calendar to check what kind of event was made.

Would anyone know what would be the cause for this?

Logcat is telling me this:
D/Calendar: Created event with ID 168

which means the event was created so it did it’s job.
Although this seems to happen, and I am unable to create any events that stay there permanently.

I did try to use createEventInteractively, which apparently does correctly create a event that stays and is not a birthday event.

If anyone could guide me on this issue, I’d very much appreciate it.
Using the interactive event is not an option for us.

Typical debugging process…have you isolated it to the plugin or the ionic native wrapper? Is the plugin up to date and using the latest version?

Dear mrhartington,

Yes the plugin is up to date, I found out that when doing createEvent it would not have any options that would be associated to which calender it should put the event in, hence it would put it in the birthday calendar since that had the first id for me.

The birthday calendar is a read only calendar, meaning anything I manually put in there will be removed automatically.

I figured out that when I do createEventWithOptions, there is a option to pass the calendarId and calendarName, which makes it so it will select the proper calendar to put the events in.

Eventually I figured out that I was passing an object to the function that would create the event with options, but this object was created with: [{}] instead of {}, this would cause the id and name of the calendar not being passed through as it should.

After fixing that issue everything seems to be resolved.