WP8.1 and WP10 differences

2019-02-13 14:47发布

With Windows Phone 8.1, next line worked well but now when users are changing to Windows 10 phones, devices are failing.

ProductLicense inAppLicense = CurrentApp.LicenseInformation.ProductLicenses["Keyfor"];

As mentioned worked with WP 8.1 nicely and license information was read and stored nicely. Now with Windows 10 phones, that line just generates exception.

"Exception from HRESULT: 0x803F6107".

Same result with real devices as well with emulators.

So, how can I check LicenseInformation from Windows 10 phones with WP 8.1 project environment (i.e code made with 8.1 projects)?

2条回答
一纸荒年 Trace。
2楼-- · 2019-02-13 15:21

I had the same problem in my windows 10 universal app.

The solution for me was App Package creation for upload to the store. I you run this routine, it will create a Package.StoreAssociation.xml and a StoreKey.pfx files in project directory. The prerequisite for this is that app created in store.

I guess the app needs these files to get data from correct app in the store

查看更多
beautiful°
3楼-- · 2019-02-13 15:34

The problem, at least for me, was that my Windows Store account was missing some information.

How did I come to this conclusion? I uninstalled my app from my machine. I then went to the MS Windows Store App. From there I re-installed my app. As a part of the process, the Store App complained that my account was missing this info: birthdate and location. I filled in this information, and continued the install process.

When the install from the store finished, I ran my app, and it worked!

If your problem is the same as mine, you could probably also try to download ANY app from the store to see if you are prompted for the missing information. If not, try to reinstall your app from the Store and see if that does it.

查看更多
登录 后发表回答