You can get all the values under a specific registry key, filter the data from the values and then get the name of the value. In the following example, I list the values under the CurrentVersion key, filter the values based on data (games) and get the value name (SM_GamesName). For this example, the PSRemoteRegistry module is required :
Import-Module PSRemoteRegistry $key = 'SOFTWARE\Microsoft\Windows\CurrentVersion' Get-RegValue -Hive LocalMachine -Key $key | Where-Object {$_.Data -eq 'games'} | Foreach-Object { $_.Value } SM_GamesName
source share