1

I have created an application which contains certain date option.

Now suppose on some date I have write notes my app.

Now when I press my submit button, these notes are save in the device calendar.

So, is it possible to save the data that you used in your application directly in the device calendar based on the date you have selected for saving data? Moreover, when I delete my data from the app, the data saved in the device calendar is also deleted.

nhahtdh
  • 55,989
  • 15
  • 126
  • 162
AndroidDev
  • 4,521
  • 24
  • 78
  • 126

2 Answers2

1

Take a look at this link: http://code.google.com/apis/calendar/data/2.0/developers_guide.html

There is a Java library for API version 2.0. Try using that to modify a particular user's Google Calendar.

You can find the current user's e-mail ID (Google account) from this question: How can you get an Android user's email address?

Update:

Here is a sequence that might work:

Obviously there might be steps I have missed. Do try these out and read the documentation to see if some steps are required in between

Community
  • 1
  • 1
sparkymat
  • 9,938
  • 3
  • 30
  • 48
  • its quiet complicated here..all things are bounce from my head..can u please explain me with simple examples – AndroidDev Jun 27 '11 at 14:06
  • hi sparky..so do you find any simple example for that. – AndroidDev Jun 28 '11 at 04:55
  • No. I didn't. The only way may be to go through the documentation. I will update the answers with some steps you can follow. – sparkymat Jun 28 '11 at 05:04
  • 1
    hey spark i read all the documents..but its quiet complicated..actually is there are no application done that add events in the device calender..i means to say that i dont need such complicated work what i need is simply add event from my app to device calender – AndroidDev Jun 28 '11 at 07:01
  • Perhaps there is no simple way. I couldn't find one anyway. – sparkymat Jun 28 '11 at 07:02
  • i am sending you a link where they give a code for adding event in the device calender..u check i try to implement it but not sucess..i think you can do it..http://www.andreabaccega.com/blog/2010/08/09/add-events-on-google-calendar-on-android-froyo/ – AndroidDev Jun 28 '11 at 07:17
  • will try it at home later, and let you know – sparkymat Jun 28 '11 at 07:18
  • sorry.. not yet.. got caught up with work.. in fact, still busy.. will get back to you – sparkymat Jun 29 '11 at 07:47
  • @sparkymat let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/950/discussion-between-anshuman-and-sparkymat) – AndroidDev Jun 29 '11 at 08:37
0

To modify a user's Google Calendar, use the Google Calendar GData API.

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491