In process of J2ME program development, for certain need, often need to acquire the mobile phone number of the user, but this function is in however standard J2ME kind did not offer in the library.
When the network of CMWAP means join with in use mobile country, shift meets China put the mobile phone number of the user in the head information that a name is X-up-calling-line-id, can take this head news through reading, acquire the mobile phone number of the user, specific code is as follows:
String Usermphone = Http.getHeader("x-up-calling-line-id" );
Among them the object that Http is HttpConnction type.
Hot Tags: