Leandro Coutinho wrote:I just want to know the number that is calling.
Can you explain in more detail what kind of program you are trying to write and how you think exactly it should work?
Right now we have no idea what you mean exactly. Do you want a regular expression to check whether a
string contains a valid phone number? Or do you have a phone connected to a computer somehow, and when the phone rings you want the computer to see what number is calling? Or are you writing software on a phone with Java ME?
I've been in a project once where a client had a big telephone dispatch computer, which had a special API in Java you could use to recognise and route phone calls to employees.