Use Nuget Package,Through Debug WriteLine (download. PackageMoniker);
Debug WriteLine (download. PackageUri);
Taking Microsoft's "Media Player" as an example, it was found that the actual file and description names downloaded from the download link were inconsistent and all were incorrect. Downloading the application package resulted in a framework package, while downloading the framework package resulted in an application package.
Code, both initialization methods have been tried:
使用nuget包,顺序都是错的
通过Debug.WriteLine(download.PackageMoniker);
Debug.WriteLine(download.PackageUri);
以微软“媒体播放器”为例,发现下载链接下载的实际文件和描述名称不一致,全部都是错的,下载应用包得到的是框架包,下载框架包得到应用包。
代码,两种初始化方式都试过了:
DisplayCatalogHandler dcathandler = new DisplayCatalogHandler(DCatEndpoint.Production, new Locale(Market.US, Lang.en, true)); IList<PackageInstance> r; await dcathandler.QueryDCATAsync(productId); r=await dcathandler.GetPackagesForProductAsync(); List<packlink> ret = new List<packlink>(); foreach (var download in r) { ret.Add(new packlink(download.PackageMoniker + ".Appx", download.PackageUri.ToString())); Debug.WriteLine(download.PackageMoniker); Debug.WriteLine(download.PackageUri); }
Use Nuget Package,Through Debug WriteLine (download. PackageMoniker);
Debug WriteLine (download. PackageUri);
Taking Microsoft's "Media Player" as an example, it was found that the actual file and description names downloaded from the download link were inconsistent and all were incorrect. Downloading the application package resulted in a framework package, while downloading the framework package resulted in an application package.
Code, both initialization methods have been tried: 使用nuget包,顺序都是错的 通过Debug.WriteLine(download.PackageMoniker); Debug.WriteLine(download.PackageUri); 以微软“媒体播放器”为例,发现下载链接下载的实际文件和描述名称不一致,全部都是错的,下载应用包得到的是框架包,下载框架包得到应用包。 代码,两种初始化方式都试过了:
DisplayCatalogHandler dcathandler = new DisplayCatalogHandler(DCatEndpoint.Production, new Locale(Market.US, Lang.en, true)); IList<PackageInstance> r; await dcathandler.QueryDCATAsync(productId); r=await dcathandler.GetPackagesForProductAsync(); List<packlink> ret = new List<packlink>(); foreach (var download in r) { ret.Add(new packlink(download.PackageMoniker + ".Appx", download.PackageUri.ToString())); Debug.WriteLine(download.PackageMoniker); Debug.WriteLine(download.PackageUri); }