0

I have tried package manager classes to get the list of installed packages in windows 10 machine.

PackageTypes type = PackageTypes.Main;                                           
IEnumerable<Package> packages = (IEnumerable<Package>) packageManager.FindPackagesWithPackageTypes(type); 
foreach(var package in packages){
    Console.WriteLine("Name: {0}", package.Id.Name);
    Console.WriteLine("FullName: {0}", package.Id.FullName);
    Console.WriteLine("Version: {0}.{1}.{2}.{3}", package.Id.Version.Major, package.Id.Version.Minor,
        package.Id.Version.Build, package.Id.Version.Revision);
}

When I used the above code, getting all packages including games installed in windows 10 machine ,

but how can I separate only games from the list? enter image description here When I searched in ms store I found that In mss tore app there is filter in which I can able to select the games option which will show all games installed in the machine from ms store, any idea how they are filtering these games?

Sateesh Kumar
  • 31
  • 2
  • 7
  • try this [link](https://stackoverflow.com/a/39435219/11362349) –  Jan 21 '20 at 08:14
  • I need not only steam apps, the games installed using windows app store, any idea? – Sateesh Kumar Jan 21 '20 at 08:25
  • 6
    How do you make the distinction between what is a game and not? – AsheraH Jan 21 '20 at 08:34
  • I think you can't distinct game from other apps. If you know what apps should be installed on end user's PC you can create 'white list'. Get all packages and yeild all that doesn't match your list. – Krivitskiy Grigoriy Jan 21 '20 at 08:41
  • Can any one has any idea how to get the installed games list in windows 10 machine using any other language like C++? – Sateesh Kumar Jan 22 '20 at 05:49
  • 1
    See [Is the Windows 10 Game Bar extensible?](https://gamedev.stackexchange.com/q/150601/10408). – Theraot Feb 03 '20 at 07:04
  • 1
    There is no way to do this. The categorisations in the MS store are entirely within the store, they are not exposed to end-users in any sort of API. – Ian Kemp Feb 03 '20 at 07:09

0 Answers0