The requirement is, in a shared PC admin want to install the software for selected users if AppData folder exist for the user. Users can be local or remote but the profile data should exist in the local PC
I have tried few solution from SO, but couldn't figured out a right solution
Solution 1 : This returns all the remote users, many doesn't have profile data in the local PC
Solution 2 : Iteratre through all the profiles available under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList
in the registry
Is there any better efficient way than Soultion 2?