none
[WP8.1]how to implement in-app purchase in windows phone 8.1 RRS feed

  • Question

  • Hi all,

    currently I am new in windows phone 8.1 c# store application development .  my application need in-app purchase , I refer so many links on Internet I found documents on windows phone 8 and windows phone 8.1 silverlight apps only , no specific document for windows phone 8.1 store application . as per windows phone 8 document I submit my application as beta app, and create one consumable product , for testing in currentAppsimulator class I have created one testwindoesphone.xml file and working fine but I dont know how to construct code with currentApp class. I have refer https://msdn.microsoft.com/en-us/library/windows/apps/xaml/dn532254.aspx ,  but every time I found 805a0194  error while I used CurrentApp class . please guide me for enalble in-app purchase in my windows phone 8.1 application . 

     async private void btnCurrentApp_Click(object sender, RoutedEventArgs e)
            {
                LicenceInfo = CurrentApp.LicenseInformation;
                //await CurrentApp.RequestProductPurchaseAsync("PremimumVersion",false);
                
                if (LicenceInfo.ProductLicenses["PremimumVersion"].IsActive)
                {
                    Debug.WriteLine("Already Purchased");
                }
                else
                {
                   // await CurrentApp.RequestAppPurchaseAsync(false);
                    //await CurrentApp.RequestProductPurchaseAsync("PremimumVersion");
                    await CurrentApp.RequestProductPurchaseAsync("PremimumVersion");
    
    
                    var productLicenses = CurrentApp.LicenseInformation.ProductLicenses;
    
    
                    MaybeGiveMeGold(productLicenses["Premimum App"], 0);
                    //PurchaseResults purchaseResults = await CurrentApp.RequestProductPurchaseAsync();
                    //Debug.WriteLine("Purchase Status :: " + purchaseResults.Status);
                  
                }
    
            }

    please let me know that where to put appid or guid in appxmanifest file . 

    Note: I have already done store association for beta app. 

    Please help me out for that , sorry for poor English 

    Thanks in advance 


    Thursday, May 28, 2015 2:50 PM

Answers

All replies