开发者

webService, app widget, android

I am new to android and making an app that's basically an appwidget

I have a lot of tutorial but could not figure out what to do. here is my problem

I have to make a app that checks a php page like... xyz.com/home.php. As soon as user types this page the php page returns the status via url like if status is busy it will return URL like xyz.com/home.php?status=busy or if status is onli开发者_运维百科ne the URL will change to home.php?status=online

Now I want to make a appwidget that checks this page every 10sec and changes the icon of widget as status changes

How to do this. I am trying to use use webview but its not working. how to use service to connect to app and change app icon please share a little codes also

Thanks


Make sure to look at the tutorial reference for AppWidgets as part of the Android Developer resource: http://developer.android.com/guide/topics/appwidgets/index.html. This will have all of the information and code examples you will need.

More specifically, WebViews are not a supported View widget for homescreen AppWidgets. Instead, you will have to pull the WebPage using a background service, then check the status, and then update an appropriate ImageView in the AppWidget based on the status.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜