tags:

views:

106

answers:

2

Hello In my android application i would like get all the available APN and check if the client APN is available. I would like to run my app using this client APN.

Is there any way to achieve this in android.

Thanks in advance :)

A: 

This might not answer your question directly. Have a look at this . Though keep in mind that this code is for reference only and should not be used in your app.

To get defined APN:

Cursor c = getContentResolver().query(Uri.withAppendedPath(Telephony.Carriers.CONTENT_URI, "current"), null, null, null, null);

And then refer to Telephony.Carriers for relevant columns.

Asahi
A: 

I would refer you to here (Android source for the preferences) which is what I modeled mine after. Hope it helps!

Mlove