Android 中的日历、触发、Web 服务访问
你好,我 我是安卓新手.. 我安装了三星 Galaxy 3 和 android 2.1.. 我想构建一个小部件如下..
1.我想访问手机日历..(谷歌搜索了很多不同的答案,但没有 wokrin..)(jimblackler.net/blog/?p=151 不起作用).. 由于没有可用的公共 API,即使我能够使用谷歌日历(来自网络的日历)也没关系。让我知道哪个更容易实现。我只想读取事件..
2.如何在特定时间触发事件.. 说当 3:00 时它应该调用一个函数.. 是否可以 ?如果是这样,如何
3.我想将两个字符串发送到服务器并接收和其他文本作为结果。这将是最简单的编码方法?有一个 C# Web 服务..?或者只是在服务器上使用接受少量参数的 php 脚本?
多谢。 :)
Hello m
I am new to android..
I have samsung galaxy 3 and android 2.1 installed in it..
I want to build an widget as follows..
1.I want to access calendar of phone.. (googled a lot found diffrent answers but none wokrin..) (jimblackler.net/blog/?p=151 not working)..
since no public api is available it will be ok even if am able to use google calendar(the one from web).. letme know whichever is easier to implement. I just want to read events..
2.How do I trigger events on a specific time.. say when it is 3:00hrs it should call a function..
Is it possible ? if so how
3.I want to send two strings to a server and recieve andother text back as result. which would be the easiest way to code ?? have an c# web service..? or just use a php script on server accepting few parameters?
thanks a lot. :)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
第一个问题:日历访问:这基于 content://calendar/calendars URI。
首先,确保您的应用程序定义了 android.permission.READ_CALENDAR 权限。
获取日历 ID 和显示名称:
处理特定日历:
Second Question: Scheduling Events:
Basically, you should use the AlarmManager class, see the android SDK for details.
Example to set the event 3 hours from now:
Third Question: Yes, I suggest the PHP approach
First Question: Calendar access: This is based on the content://calendar/calendars URI.
First, make sure your application defines the permission android.permission.READ_CALENDAR.
Get the calendars IDs and display names:
Work on a specific calendar:
Second Question: Scheduling Events:
Basically, you should use the AlarmManager class, see the android SDK for details.
Example to set the event 3 hours from now:
Third Question: Yes, I suggest the PHP approach