Replies: 1 comment 3 replies
-
Unfortunately, since you haven't given information on what you are actually doing, all I can do is point you at the documentation. First, the StoreContext documentation states that that it requires that you use IInitializeWithWindow. There should be a C# interop means of doing this if you are using C#. Second, Windows Runtime APIs not supported in desktop applications states that members with the Request naming pattern uses the Windows.UI.Popup class, and that means it requires a WinRT CoreWindow, which is just unavailable in desktop applications. Yes, WinUI 3 is still a desktop application. In this case, I don't think this means that you can't use it, but it means that you must use IInitializeWithWindow in order to tell the class to use a desktop window instead. Third, In-app purchases and trials states that the StoreContext class must be configured to use a desktop HWND as the parent for modal dialogs. So this agrees with what I already stated above. So to use StoreContext, you have to do the following steps.
To give an actual code examples, for C++
For C#
|
Beta Was this translation helpful? Give feedback.
-
Hello,
I am unable to use the Windows.Services.Store API with WinUI 3, but I cannot seem to be able to do anything.
I am unable to get the products add-ons (the app is associated with the Microsoft Store), the error 0x803F6107 still is thrown. I am also unable to use StoreContext.RequestRateAndReviewAppAsync(), the app crashes with the error "Access violation error".
Thanks in advance, any help is appreciated.
Beta Was this translation helpful? Give feedback.
All reactions