(I appoligize by advance for my bad English :) )
I'm actually working on a Windows Phone store application (wp8.1), and I need to display a selector with country name (and few other informations).
I am using libphonenumber library to get country information,but also to check that the number the user enter is in correct format with the selected country code. You can find more information about that library here.
So... this library gives me supported countries. The information I can get (and use) for each country is :
- Country TwoLetter code : (for example, for France : FR)
- Country Numeric code : (for example, for France : 33)
But I also need to display Country Full name (for exaple, for France : France) :)
I have tried to use CultureInfo to get the Name from the TwoLetter Code
string name = new CultureInfo("FR").DisplayName;
but that didn't worked... Actualy sometimes it returns the language, and sometimes it crashes. I know where the problem comes from, CultureInfo should take the parameter this way : "FR-fr", then it will return "français (France)". But all I have is "FR" or 33...
Is there any other ways to get country name, using this two information ?
Thank you by advance !
Roman.