Each BlackBerry smartphone that is active on a wireless network has a unique identifier known as the International Mobile Subscriber Identity (IMSI). On GSM® networks, the IMSI is associated with the Subscriber Identity Module (SIM) card. On Code Division Multiple Access (CDMA) networks, the IMSI is assigned to the BlackBerry smartphone.
An application may benefit from knowing the country associated with the IMSI. For example, an application might launch different URLs in the BlackBerry® Browser, depending on the country in which the wireless service account is based.
The following sample code demonstrates how to retrieve the IMSI of the BlackBerry smartphone and how to determine the Mobile Country Code (MCC) that is embedded in the IMSI: