views:

53

answers:

1

Lets consider that I am connected to internet through 3G in my App. When a wi-fi hot spot seems to be appearing, can I programmatically switch to the wi-fi. Is this vice-versa condition possible?

+3  A: 

The iPhone does this automatically by itself.

If no known WiFi-network is found, it uses 3G. If it finds a known WiFi-network, it uses that instead.

If any WiFi-network is found, and your application uses internet, the iPhone automatically presents an UIAlertView and lets the user log in to a WiFi-network. If no network is chosen, it uses 3G again.

Apple does not let apps control these things.

Emil