Here are the URI and package name changes between 2.1 and 2.2:

- Content provider URI -
Old: content://calendar/
New: content://com.android.calendar/

- Calendar app package name -
Old: com.android.calendar
New: com.google.android.calendar

More information is available on the XDA forums [1].  Hope this helps.

Adam

[1] http://forum.xda-developers.com/showthread.php?t=688095

On May 25, 3:34 am, Andreas Streim <[email protected]>
wrote:
> Hi everybody,
>
> my app uses the internal calendar via the not officially, but in some
> articles on the web mentioned methods. So I have some lines to read
> all available calendars:
>
> String[] projection = new String[] { "_id", "displayName" };
> Uri calendars = Uri.parse("content://calendar/calendars");
> Cursor managedCursor = act.managedQuery(calendars,
> projection,"access_level>300", null, null); /* "selected" */
> if (managedCursor.moveToFirst()) {
> etc.
>
> It works well with Android 1.5 to 2.1, but since Froyo there seems to
> be a problem. A Nexus user with Froyo gets force close and sent me a
> log with this line:
>
> 05-24 18:55:04.308 E/AndroidRuntime( 1467): Caused by:
> java.lang.NullPointerException
> 05-24 18:55:04.308 E/AndroidRuntime( 1467): at
> streim.de.quickaddroid.MeinKalender.init(MeinKalender.java:27)
>
> that's the if-line.
>
> Can anybody give me a hint what Google has changed to the calendar since 2.1?
>
> I know the method to access the calendar was never official, but there
> was no alternative. And it's not a good user experience, when apps you
> have used before stopped working. And the (hobby) programmer cannot do
> anything, because calendar is not part of the SDK and I don't have a
> Nexus :-(
>
> Greetings,
> Andreas
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group 
> athttp://groups.google.com/group/android-developers?hl=en

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to