0

I'm using the libPhoneNumber-iOS library to get the supported regions and verify the user phone number is valid or not. But I'm not able to find any method which returns me the country dialing code(like +91 for India).

Is this achievable through the library or I have to manually hard code all the country dialing codes?

Any help is appreciated.

Logunath
  • 477
  • 1
  • 8
  • 20
  • can you show ur code – Anbu.Karthik Sep 20 '16 at 11:05
  • I wan to know any method in the library that achieve this goal? I'm using https://github.com/iziz/libPhoneNumber-iOS – Logunath Sep 20 '16 at 11:07
  • I guess through the library I'm using its not possible. I have hard coded all the country dialing codes in a separate class and utilized the class to show it in a view. – Logunath Sep 21 '16 at 05:47
  • library I don 't know but manually we can get the country dial code is valid or not , but we can't find its is the valid mobile number – Anbu.Karthik Sep 21 '16 at 05:49
  • We can do that through the library. There is method called isValidNumber, you can utilize the method to validate a number. – Logunath Sep 21 '16 at 06:05
  • ok i m not used that library, ok now what the question here... – Anbu.Karthik Sep 21 '16 at 06:06
  • Question is above. Answer is to hard code the dialing codes. I was just looking for any way that I can do without hard coding dialing codes. – Logunath Sep 21 '16 at 06:13

0 Answers0