Question

I used this method in WP8 to get the user property :

object userHashId;
UserExtendedProperties.TryGetValue("ANID2", out userHashId);
_userId = userHashId.ToString();

msdn link

But I cannot find these in Windows Phone 8.1. Are there any new API for this , or any alternative.

Was it helpful?

Solution

AFAIK it isn't possible under WinRT apps - the link you have provided stays for WP8.1 Silverlight Apps - then I suspect you are trying to develop under WinRT - API Reference.

You can read more from here, also here at SO and at this article.

Following this answer, maybe the code below will help you:

HardwareToken myToken = HardwareIdentification.GetPackageSpecificToken(null);
IBuffer hardwareId = myToken.Id;

There is also a Guidance on using the App Specific Hardware ID (ASHWID) to implement per-device app logic.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top