开发者

Blackberry - getLocation() method cannot be called from event thread

I want to get the longitude and latitude of device.开发者_JAVA技巧 I used location api to get the longtitude and latitude the problem now I am facing is that I could not call the getLocation() method inside button click event. It throws an error as getLocation() method cannot be called from event thread.Can any one tell me how to solve this problem?


You simply create another thread and call getLocation() from that thread. See the documentation for java.lang.Thread in the API documentation.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜