Im trying to understand the Widget Sample .
I thought I would try to show the temp with the ICOSWorldForecast lib.
The code works great on a button .
I am trying to get it to work in the Widgets example.
I wrote this
It makes the app force close.
in the log it shows.
What am I doing wrong in the service widget sample ?
Thanks
I thought I would try to show the temp with the ICOSWorldForecast lib.
The code works great on a button .
I am trying to get it to work in the Widgets example.
I wrote this
B4X:
Sub gettemp
Dim w As ICOSWorldForecast
Dim s As String
w.Initialize("w")
w.ApiKey="111111111111111111111"
s= w.GetList("wise ","Search Results",False)
w.CityName= s
rv.SetText("Label1",s)
Log(s)
It makes the app force close.
in the log it shows.
B4X:
widgetservice_settemp (java line: 159)
android.view.WindowManager$BadTokenException: Unable to add window -- token null is not for an application
What am I doing wrong in the service widget sample ?
Thanks
Last edited: