Answered by:
How can i know if the user's current region belongs to certain area?

Question
-
Hello!
I am developing a game for Windows 8 and i want to determine if the current region of the user belongs to a determined area (for rating purposes). I started using Windows::Globalization::GeographicRegion::Code and that works fine for countries by themselves, but i don't know if i can use the same to know if a country is inside Americas or Europe region. Anyone knows if there's a better way to do this?Monday, December 3, 2012 7:13 PM
Answers
-
Hi,
I searched the document and found that there maybe no direct way to get the continent.
http://msdn.microsoft.com/en-us/library/windows/apps/windows.devices.geolocation.civicaddress.aspxMaybe we can get the country first, and then keep all the country in a map with continent. Then we can lookup this map to get the continent.
Best regards,
JesseJesse Jiang
MSDN Community Support | Feedback to us
Develop and promote your apps in Windows Store
Please remember to mark the replies as answers if they help and unmark them if they provide no help.- Marked as answer by Jesse Jiang Monday, December 10, 2012 8:26 AM
Thursday, December 6, 2012 5:46 AM -
That's pretty much what i did in the end, thanks for the help anyway
- Marked as answer by Jesse Jiang Monday, December 10, 2012 8:26 AM
Thursday, December 6, 2012 12:38 PM
All replies
-
Hi,
How about get these information from IP address?
You can follow this thread to get the IP address in Windows Store App.
http://social.msdn.microsoft.com/Forums/en-US/winappswithnativecode/thread/e9c3a808-6b29-4885-964d-0c961e8ac65d/Best regards,
JesseJesse Jiang
MSDN Community Support | Feedback to us
Develop and promote your apps in Windows Store
Please remember to mark the replies as answers if they help and unmark them if they provide no help.Wednesday, December 5, 2012 11:48 AM -
For that matter i think is easier to use Geolocation (http://msdn.microsoft.com/en-us/library/windows/apps/windows.devices.geolocation.aspx), but i have the same problem: i can get the country, postal code and even latitude/longitude of the device's position, but i need a way to know to which continent that location belongsWednesday, December 5, 2012 1:20 PM
-
Hi,
I searched the document and found that there maybe no direct way to get the continent.
http://msdn.microsoft.com/en-us/library/windows/apps/windows.devices.geolocation.civicaddress.aspxMaybe we can get the country first, and then keep all the country in a map with continent. Then we can lookup this map to get the continent.
Best regards,
JesseJesse Jiang
MSDN Community Support | Feedback to us
Develop and promote your apps in Windows Store
Please remember to mark the replies as answers if they help and unmark them if they provide no help.- Marked as answer by Jesse Jiang Monday, December 10, 2012 8:26 AM
Thursday, December 6, 2012 5:46 AM -
That's pretty much what i did in the end, thanks for the help anyway
- Marked as answer by Jesse Jiang Monday, December 10, 2012 8:26 AM
Thursday, December 6, 2012 12:38 PM