Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
BlackBerry Development Advisor
MSohm
Posts: 14,757
Registered: ‎07-09-2008
My Device: BlackBerry Passport

Carrier Information ...

Quote from the previous forum:


VipulPathak

Posts: 47
From: Columbia, MD
Registered: Apr, 2008

Carrier Information ...
Posted: Jun 30, 2008 7:42 AM
 
Hi,

I need to find the following. If there is any way to programmatically detect the following information, please reply:

(1) Active Carrier Name
(2) Home Carrier Name
(3) Mapping of MCC and MNC, with actual name in string.

Any help with the above will be appriciated.

Thanks in advance !

*(Vipul)() ;

 


gmay

Posts: 231
Registered: Jun, 2007

Re: Carrier Information ...
Posted: Jun 30, 2008 12:43 PM
 
The information required can be obtained using the RadioInfo class:

http://tinyurl.com/698k4d

Gordon
BlackBerry Developer Journal
www.blackberrydeveloperjournal.com

 

VipulPathak

Posts: 47
From: Columbia, MD
Registered: Apr, 2008

Re: Carrier Information ...
Posted: Jul 9, 2008 10:49 AM
 
I am successful in obtaining the Active Carrier Name, but the other two (Home Carrier Name, Mapping of MCC and MNC) are still, I am trying to find ways to detect them ...

Anyone?

 

msohm

Posts: 2,246
Registered: Jul, 2005

Re: Carrier Information ...
Posted: Jul 9, 2008 7:17 PM
 
You can read that information from the GPRSInfo class.

Mark Sohm
BlackBerry Developer Journal
www.blackberrydeveloperjournal.com

 

VipulPathak

Posts: 47
From: Columbia, MD
Registered: Apr, 2008

Re: Carrier Information ...
Posted: Jul 9, 2008 10:23 PM
 
That class provide methods that return numeric Ids for Home Carrier Name, MCC and MNC.

I want to obtain a string "Name" for the Home carrier. I am not sure if MCC or MNC or Network Id, can be decoded into it or we have to do some thing else.

Thanks if anyone can uncover this ...

 

VipulPathak

Posts: 47
From: Columbia, MD
Registered: Apr, 2008

Re: Carrier Information ...
Posted: Jul 15, 2008 5:37 AM
 
So any information about how to use MCC and MNC to get a string name of the network ?

You can use the getCurrentNetworkName method of the RadioInfo class can be used to obtain the name of the current network as a String.
Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker
Developer
VipulPathak
Posts: 81
Registered: ‎07-16-2008
My Device: Curve - 8320

Re: Carrier Information ...

If I understood correctly, the method RadioInfo.getCurrentNetworkName() will return the name of current network, which is as per my question is the "Active Carrier" or the Current Carrier.

 

In the home network, both the Active Carrier and the Home Carrier maps to same name. What about when the device is not in its Home network and then we want to find the name of Home Carrier?

 

The methods GPRSInfo.getHomeMCC() and GPRSInfo.getHomeMNC() returns a numeric code for Country Code and Network Code for the Home network, but still we need a String name for those codes.

 

My original question was, How to map these numeric codes to a Human readable string name ?

 

Thanks,

 

*(Vipul)() ;
BlackBerry Development Advisor
MSohm
Posts: 14,757
Registered: ‎07-09-2008
My Device: BlackBerry Passport

Re: Carrier Information ...

The BlackBerry API set does not provide a method to map carrier codes to a their name (string).
Mark Sohm
BlackBerry Development Advisor

Please refrain from posting new questions in solved threads.
Problem solved? Click the Accept As Solution button.
Found a bug? Report it using Issue Tracker