Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
422 views
in Technique[技术] by (71.8m points)

android - How to use CalendarContract class in API Level 8

After the launch of android 4, CalendarContract class is introduce to write event in device calendar. But if i have created my app using API level 8 and Now i want to use this CalendarContract class in my project done using API level 8, because in API level 8 i have use undocumented API to write event in device calendar and this code doen't work for android 4. So is it possible to use CalendarContract class in my project without changing the sdk version in manifest file, because if i change the sdk version to 14 then it allow me to use CalendarContract class and by which i can solve the issue for android 4. But on doing so my app not started running in api 8 -13, and which i dont want to do because my app is live on market. So is there any possible way to solve this problem. Please explain me with an example

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

You cannot use CalendarContract on Android devices running less than API Level 14.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...