Simulating a Windows 8 Store apps purchase

懵懂的女人 提交于 2019-12-03 07:09:07

Are you updating the WindowsStoreProxy.xml file? You have to do that otherwise the purchase will never be set to active. You don't need to call RequestAppPurchaseAsync... only the requestProductPurchaseAsync. Do this...

Run your app in debug mode breaking anywhere Open QuickWatch (SHIFT + F9) and enter Windows.Storage.ApplicationData.current.roamingFolder.path and copy the value (mine was C:\Users\jerfost\AppData\Local\Packages\{package name}\LocalState Browse to that location and open the Microsoft\Windows Store\ApiData directory Open the WindowsStoreProxy.xml file in a text editor Change CurrentApp/LicenseInformation/App/IsTrial to false Change CurrentApp/ListingInformation/Product/MarketData/Name to your unique product name That should do it. Hope that helps.

You don't have to manually edit the XML everytime, CurrentAppSimulator does it automatically.

Just check your setting in the WindowsStoreProxy.xml and ensure that 'IsTrial' is set 'false'-

<LicenseInformation>
    <App>
        <IsActive>true</IsActive>
        <IsTrial>false</IsTrial>
    </App>
    <Product ProductId="1">
        <IsActive>false</IsActive>
    </Product>
</LicenseInformation>

Remember - In-app purchases does not work in Trial version of the app.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!