Create a calendar with the ability to synchronize

I developed an application to create and synchronize a local phone calendar using the application. Now I need to synchronize this calendar on the Internet, best through my own phone account. I tried to expand the URI content value parameter (see List of API LVL parameters <8 below) by account name and type, but after that it closes.

_id sync_account _sync_account_type _sync_id _sync_version _sync_time _sync_local_id _sync_dirty _sync_mark url name displayName hidden color access_level selected sync_events location timezone ownerAccount 

Is there any other way to create an online synced Google calendar?

+2
source share
1 answer

You cannot create new ones programmatically. Instead, analyze all available with

 Uri.parse("content://com.android.calendar/calendars",null, null, null, null); 

and fill in your events in the existing one.

But make sure your event got the same

 sync_account 

and

 _sync_account_type 
+1
source

Source: https://habr.com/ru/post/913274/


All Articles