Android Question wifi getDetailedState

Encarni Moreno

Member
Licensed User
Longtime User
Hi Erel, I'm trying to get the values of the state of the wireless connection when the state change occurs, the data in NetworkInfo.DetailedState.

I'm trying to do with intents and runmethod
but only I get errors of the serious code java object:

service module

Sub Process_Globals
'Global Declared These variables will be eleven o'clock When the application starts.
'These variables can be accessed from all modules.

End Sub
Sub Service_Create

End Sub

Sub Service_Start (StartingIntent As Intent)
As String Dim r
Dim As jo JavaObject

If StartingIntent.Action = "android.net.wifi.supplicant.STATE_CHANGE" Then
Log("Paso2")
Dim NetworkInfo As JavaObject = jo.InitializeStatic("android.net.NetworkInfo").RunMethod("getParcelableExtra", Array("networkInfo"))
detail=NetworkInfo.RunMethod("getDetailedState",Null)
Log(detail)
End If

End Sub

Sub Service_Destroy

End Sub

Can you help me?
thanks in advance
 
Last edited:
Top