Tuesday 3 November 2020

How to tell if 'Mobile Network Data' is enabled or disabled (even when connected by WiFi) in iOS?

I have an app that I want to be able to use to get a connection status report after some certain time interval. Even when I am connected or associated to a Wifi network, I would like to know if data access is enabled over cellular network. This means, if after a check, I can gracefully disassociate from the wifi network, knowing that there is an available cellular connection to which the device will get connected to.

Current Reachability methods will only give me information about the availability of cellular only when am connected to that and there is not much information about getting this data before actually connecting to the interface.

Looking for a similar solution as available in android, as explained in this link.

CLARIFICATION

I am NOT looking to see if my device is having cellular capabilities. I AM trying to establish whether or not the user has enabled / disabled Data access over mobile network, and would like to know this information even if I am connected to Wifi. User can turn this on and off by going to Settings.



from How to tell if 'Mobile Network Data' is enabled or disabled (even when connected by WiFi) in iOS?

No comments:

Post a Comment