Guys... i wana make an app that immediately tells me my new IP when an old one has changed due to a possible network lapse...
so is there anything that can detect network state or a change in the network state etc???.. like how we have Phone state when its ringing... something like that? ??
it'll help when i need to use the B4A bridge. ... so i dont have to keep checking the phone IP.. and see if it's changed or still the same
You will have to create a service that periodically checks your IP and display a message, notification, etc if the IP changes, read THIS to get an idea.
yes buddy... thats exactly what i thought of but.. imagine occupying processor time with continuously having to check when the IP changed. ... when actually all we would need is a raising of an event when the Network has come back.. or re established...???
do u get what im trying to find here... Is if theres any way in b4a for us to get that state_change_in_network? ?? possible? ? any idea??... and yeah obviously use it in a service
Well, you still will have to keep checking for a change, besides, you are going to be using that while coding so, just plug your device to your charger or USB to keep the juice flowing and regarding processor time, it will be just one more service running along the tons running in your device, why worry?
There's a way to detect if you are connected to WiFi or 3G/4G (search the forums if you want more info), but in either case the IP will change, so, checking for a different IP will do the trick.
hey NJ... look what i found online. ... but its a bouncer for me..! how could you use this to incorporate a code for an app made with B4A that could do the above (detect network change state) ??