我们无法返回 Windows 应用商店应用程序的附加产品列表。
我们在 Windows 应用商店中有一个包含 3 个订阅附加组件的应用程序。这些附加组件被标记为隐藏,因为我们不希望它们只能通过我们的应用程序在商店中可见。
我们正在开发针对 Windows 16299 的应用程序的新版本。我们正在使用Windows.Services.Store
命名空间。
但是此代码仅返回附加组件列表之一
if (context == null)
context = StoreContext.GetDefault();
string[] productKinds = { "Durable" };
List<String> filterList = new List<string>(productKinds);
StoreProductQueryResult queryResult = await context.GetAssociatedStoreProductsAsync(filterList);
foreach (KeyValuePair<string, StoreProduct> addOn in queryResult.Products)
{
StoreProduct product = addOn.Value;
AddOnList.Add(product);
}
ExtendedError = null
为什么此代码仅返回附加产品列表之一?
产品已通过认证并列为“In The Store”。
Microsoft 应用程序商店需要一些时间(大约 24 小时)来启用产品/附加组件(有时还包括应用程序)来编程 API。很久以前,当我在我的应用程序中获取产品时,就发生了这种情况。
始终确保新软件包进入商店后可能需要一些时间才能更新插件/产品。
我有一些值得寻找的东西,可以通过 API 获取附加组件/产品。查看this https://developercommunity.visualstudio.com/content/problem/157004/storecontextgetassociatedstoreproductsasync-with-1.html.
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)