Re: [android-developers] Android: Add entry to the calendar

2012-08-08 Thread Michael Chan
Hi, Have a look at http://developer.android.com/guide/topics/providers/calendar-provider.html Thanks, Mike On Wed, Aug 8, 2012 at 2:40 AM, Rahul Kaushik rahulkaushi...@gmail.com wrote: Hi, I need to add an entry in android calendar please suggest. Thanks RK -- You received this

Re: [android-developers] Google Calendar API

2012-08-16 Thread Michael Chan
Have you seen http://developer.android.com/guide/topics/providers/calendar-provider.html? On Tue, Aug 14, 2012 at 1:20 PM, Kennet kennetsund...@gmail.com wrote: Hi I am new to android. I am trying to develop an app that uses google calendar but I am having a hard time understanding the

[android-developers] Re: No luck with new ICS CalenderContract

2011-10-25 Thread Michael Chan
Hi Zsolt, Your URI is content://com.android.calendar and it should be content://com.android.calendar/calendar. Can you try CalendarContract.Calendars.CONTENT_URI instead of CalendarContract.CONTENT_URI? Thanks, Mike On Oct 23, 11:57 pm, Zsolt Vasvari zvasv...@gmail.com wrote: I am trying to

[android-developers] Re: No luck with new ICS CalenderContract

2011-10-25 Thread Michael Chan
Hi Zsolt, Can you try CalendarContract.Calendars.CONTENT_URI instead of CalendarContract.CONTENT_URI? Thanks, Mike On Oct 24, 5:39 pm, Zsolt Vasvari zvasv...@gmail.com wrote: I would have expected to work, also. It's kind of frustrating that the first time we are goig to be able put out

[android-developers] Re: Fwd: Android Calendar to sync after adding events programmatically

2011-10-28 Thread Michael Chan
Hi David, If you add events programmatically, it should be sync'ed automatically. Can you give me a bit of context as what you are trying to do? Are you asking about forcing a sync when sync is disabled? Or are you writing a sync adapter and need to know when something changes? Thanks, Mike

[android-developers] Re: No luck with new ICS CalenderContract

2011-11-03 Thread Michael Chan
Hi, I believe the GoogleCalendarSyncAdapter was not included in the emulator. That's why you can't sync Google Calendars in the emulator. The new Calendar API will support viewing, adding events (not calendars) via Intents. The user will need to confirm before the event is saved. Adding

[android-developers] Re: Fwd: Android Calendar to sync after adding events programmatically

2011-11-03 Thread Michael Chan
Hi David, If your customer imports the events to Google Calendar, it is a one time copy. It will never refresh. He/she should add by url instead. See http://www.google.com/support/calendar/bin/answer.py?answer=37100 If it refreshes on the web calendar, it should automatically sync to the phone.

Re: [android-developers] Re: Fwd: Android Calendar to sync after adding events programmatically

2011-11-03 Thread Michael Chan
url 2011/11/3 Michael Chan mc...@android.com Hi David, If your customer imports the events to Google Calendar, it is a one time copy. It will never refresh. He/she should add by url instead. See http://www.google.com/support/calendar/bin/answer.py?answer=37100 If it refreshes on the web

Re: [android-developers] Re: No luck with new ICS CalenderContract

2011-11-04 Thread Michael Chan
subscription (visible and sync'ed) already set up and let them confirm it. Thanks, Ralph On Nov 3, 2:29 pm, Michael Chan mc...@android.com wrote: Hi, I believe the GoogleCalendarSyncAdapter was not included in the emulator. That's why you can't sync Google Calendars in the emulator

Re: [android-developers] Re: No luck with new ICS CalenderContract

2011-11-07 Thread Michael Chan
         e.printStackTrace();      }    } catch (IOException e) {      handleException(e);    }  } On Nov 4, 12:38 pm, Michael Chan mc...@android.com wrote: Hi Ralph, I wish I have a solution for you. That's not supported right now. The only (not so good) way is to use the browser. I will file

Re: [android-developers] Duplicate Calendar Event

2012-03-13 Thread Michael Chan
Hi Giles, The code below will add an event every time onClick is called since it's doing an insert(). If you want to modify an existing event, you need to get the event id via a query then do an update. Search for Updating Events in

Re: [android-developers] Duplicate Calendar Event

2012-03-14 Thread Michael Chan
if a particular event is already present. Basically i want a select with where clause (for title,start date and end date) On Wed, Mar 14, 2012 at 12:01 AM, Michael Chan mc...@android.com wrote: Hi Giles, The code below will add an event every time onClick is called since it's doing

Re: [android-developers] Calendar edit event force close error....

2012-03-25 Thread Michael Chan
What's error? Can you show include the stack trace? On Sat, Mar 24, 2012 at 1:08 PM, Jast Vacaty jastpower...@gmail.com wrote: Hi, I am trying to add calendar events by use my application. Event gets saved successfully. However when I try to edit event that saved successfully. I get the

[android-developers] Re: How to use AlarmManager on Dialog?

2012-04-03 Thread Michael Chan
Hi, 'new Intent(com.siitne.candelaria.notificationSystem.AvisoReceiver.class)' is not valid Intent unless com.siitne.candelaria.notificationSystem.AvisoReceiver.class is valid action. Can you try sending the intent from onClick() and make sure that works first? Thanks, Mike -- You received

Re: [android-developers] Add Weekly,Fortnightly,Monthly Recurring events to calendar.

2012-04-23 Thread Michael Chan
Hi, Please take a look at the 4th bullet in http://developer.android.com/guide/topics/providers/calendar-provider.html#add-event What do you mean by it doesn't work? What do you see in the logcat? Did you get an exception? If so, please share. What did resolver.insert() return? If the insert was

Re: [android-developers] How to build row item child views that can overlap rows, for a custom calendar application

2012-05-03 Thread Michael Chan
Hi, The day and week views are custom drawn i.e. line by line, rect by rect, etc. It does not use a ListView. The agenda view uses a ListView. One row per header or event. Nothing spans across multiple rows. The month view (starting in Honeycomb, I believe) uses a ListView. One row per week.

Re: [android-developers] How to build row item child views that can overlap rows, for a custom calendar application

2012-05-04 Thread Michael Chan
Hi, Have a look at: http://developer.android.com/guide/topics/ui/dialogs.html http://developer.android.com/guide/topics/ui/notifiers/notifications.html http://developer.android.com/guide/topics/ui/menus.html Thanks, Mike On Fri, May 4, 2012 at 3:31 PM, David Ozersky somethingcleve...@gmail.com

Re: [android-developers] Task implentation

2011-11-14 Thread Michael Chan
Hi, There's no Android API for getting Tasks data (https://mail.google.com/mail/help/tasks/). You will have to use GData directly (http://code.google.com/apis/tasks/). I believe someone has a open-source implementation already. Look around. Thanks,Mike On Sun, Nov 13, 2011 at 8:36 PM, kishore

Re: [android-developers] Re: No luck with new ICS CalenderContract

2011-12-19 Thread Michael Chan
PM, Michael Chan mc...@android.com wrote: We will be publishing a developer guide for Calendar APIs with more details on the set of supported intents as well as code snippets. Great! Be sure to spread the news when they're released. :-) Thanks! -- Mark Murphy (a Commons Guy) http

Re: [android-developers] Is google calendar api is public yet

2011-12-19 Thread Michael Chan
The developer guide is available at http://developer.android.com/guide/topics/providers/calendar-provider.html On Sun, Dec 18, 2011 at 6:09 PM, TreKing treking...@gmail.com wrote: On Thu, Dec 15, 2011 at 3:39 PM, Bhupi bhupendr...@gmail.com wrote: I am planning to use calender api and couldn't

Re: [android-developers] ICS calendar event setup issue

2012-02-17 Thread Michael Chan
Is there a way to make it show the day like Gingerbread did? No. We have a bug internally to get that fixed. Thanks, Mike On Thu, Feb 16, 2012 at 9:21 AM, Greg Lozano-Buhl g...@lozano-buhl.com wrote: I've noticed that ICS no longer shows the day of the week corresponding to the selected date

Re: [android-developers] Calendar on Emulator with ICS

2012-03-08 Thread Michael Chan
Hi, Try the following: adb root wait a couple seconds adb shell sqlite3 /data/data/com.android.providers.calendar/databases/calendar.db INSERT INTO Calendars

Re: [android-developers] Event listner for calender event like meetings in ICS

2012-03-08 Thread Michael Chan
Hi, There's nothing built-in for that. If I were to implement that, I would: 1) Write some code that queries the Calendar provider and have AlarmManager wake up the phone and send you an intent at the appropriate times for the remainder of today. This method may be called more frequently then

Re: [android-developers] ICS : Why this source code crash in query ?

2012-05-15 Thread Michael Chan
Hi, What do you see in logcat? i.e. what's the crash? Also does your app have calendar read permission? http://developer.android.com/guide/topics/providers/calendar-provider.html#manifest Thanks, Mike On Mon, May 14, 2012 at 12:43 PM, chronogps chrono...@free.fr wrote: I try to read google

Re: [android-developers] How to acheive feature like this

2012-05-16 Thread Michael Chan
It is a custom view drawn on a canvas. http://developer.android.com/guide/topics/graphics/2d-graphics.html#draw-with-canvas On Wed, May 16, 2012 at 5:57 AM, zerocool luvme...@gmail.com wrote: Hi all, Can any one tell me how can i acheive feature like this, the bar diagrams feature

Re: [android-developers] Calendar EditEventHelper test case

2012-06-13 Thread Michael Chan
Thank you. I will integrate your fix into the repro. On Mon, Jun 11, 2012 at 6:48 AM, Daniel Kang doojin.k...@gmail.com wrote: Hello, I'm doing some Unit Test with Android Calendar application. In the test code in EditEventHelperTest.java, lots of testSaveEvent* encountered

Re: [android-developers] Custom alarm for calendar events

2012-06-20 Thread Michael Chan
Sorry. The stock Calendar app does not play different sounds for different events. There's no API in the provider to support this either. On Wed, Jun 20, 2012 at 3:40 AM, Sourav Howlader sourav.howla...@gmail.com wrote: Hi All, I am trying to create events in default Calendar and set alarm for

Re: [android-developers] GoogleCalendarSyncAdapter - any limit on syncing calendar events from google server

2012-06-29 Thread Michael Chan
Hi, The GoogleCalendarSyncAdapter's sync window is currently one month back and one year forward. It won't sync any event that ended earlier than a month ago. GoogleCalendarSyncAdapter does not have a limit on the number of event. Of course, there storage limits and the database will be slow and

Re: [android-developers] Re: Android app with google calender

2012-07-09 Thread Michael Chan
Here's a developer guide with code snippets: http://developer.android.com/guide/topics/providers/calendar-provider.html On Mon, Jul 2, 2012 at 2:40 AM, Ali Chousein ali.chous...@gmail.com wrote: Certainly it is possible. Take a look at the CalendarContract interface:

Re: [android-developers] Why Android will always delete the calendar?

2012-07-10 Thread Michael Chan
Hi, The provider deleted the calendar because it is not associated with an account/type. As you have discovered, we added the CalendarContract.ACCOUNT_TYPE_LOCAL for your use case. Unfortunately, it was introduced in API 15 when we opened up the calendar api. Thanks, Mike On Sat, Jul 7, 2012 at

Re: [android-developers] After Free Trial is end

2012-10-17 Thread Michael Chan
Hi Julia, From http://developer.android.com/guide/google/play/billing/billing_subscriptions.html As with other in-app products, you configure and publish subscriptions using the Developer Console and then sell them from inside apps installed on an Android-powered devices. In the Developer

Re: [android-developers] Inserting past event in local android calendar in Froyo

2012-10-23 Thread Michael Chan
Hi, The Instances table is lazily populated. You don't see them if you are looking via sqlite3. If you do a query via the ContentProvider interface, you should see the instances for the events. Thanks, Mike On Sat, Oct 20, 2012 at 12:54 AM, Bharat Parikh bharatpa...@gmail.com wrote:

Re: [android-developers] Empty EditText when turning screen on and Screen lock set to 'None'

2012-10-30 Thread Michael Chan
Do you have an android:id set for the EditText? See http://developer.android.com/reference/android/view/View.html#attr_android:saveEnabled On Tue, Oct 30, 2012 at 3:36 PM, pushbit push...@gmail.com wrote: I'm having a problem where an EditText in landscape/full screen mode becomes empty after

Re: [android-developers] Re: Androin 2.2 calendar source code

2012-11-14 Thread Michael Chan
Hi, Not sure if you are looking for UI or data. There's no platform UI for the calendar like in MapView. You will have to build that yourself or use someone else's. For calendar data, have a look at http://developer.android.com/guide/topics/providers/calendar-provider.html Thanks, Mike On

Re: [android-developers] Is there a convention for the columns CalendarContract.EventsColumns.SYNC_DATA1 - SYNCDATA10?

2012-11-14 Thread Michael Chan
Hi, The SYNC_DATA* columns are reserved for the sync adapters to use.The GoogleCalendarSyncAdapter can use it for any purpose and change the usage whenever it wants. There's no standard convention. If you are using a sync adapter, use it in any way to fit your needs. how can I make sure

Re: [android-developers] Is there a convention for the columns CalendarContract.EventsColumns.SYNC_DATA1 - SYNCDATA10?

2012-11-14 Thread Michael Chan
was recently inserted or updated, especially since there is no DATE_LAST_UPDATED column in the calendar provider? Am I missing something? Best regards, Christopher On Wednesday, November 14, 2012 6:58:02 PM UTC+1, Michael Chan wrote: Hi, The SYNC_DATA* columns are reserved for the sync adapters

Re: [android-developers] Re: Is there a convention for the columns CalendarContract.EventsColumns.SYNC_DATA1 - SYNCDATA10?

2012-11-15 Thread Michael Chan
I'm calling as a sync adapter. Are you writing a sync adapter? If not, you shouldn't be doing that. The GoogleCalendarSyncAdapter can change the meaning of the sync_data columns at anytime so you can't rely on it. If you modify the events, the dirty bit won't be set and the real syncadapter

Re: [android-developers] How to get events of a specific calendar from android 2.3

2012-11-19 Thread Michael Chan
Hi, You can do that by adding a selection/selectionArgs pair that matches CalendarContract.Events.CALENDAR_ID with the calendar id of the specific calendar. Search for selectionArgs in http://developer.android.com/guide/topics/providers/calendar-provider.html for examples. Thanks, Mike On Mon,

Re: [android-developers] Emulator 4.0.3 calendar create event not shown

2013-01-02 Thread Michael Chan
Hi, The month is base 0 i.e. December = 11. Try fixing that first. Another thing to check is to make sure that the calendar is being displayed - check the calendar in Calendar - Menu - Calendars to display. If the calendar is not visible, go to Calendar - Menu - Calendars to sync and check the