Search for text file in multiple locations

Hello,

I need to look for a text file in these locations-

  1. C:\Windows\
  2. C:\Windows\SysWOW64\
  3. C:\Users[Username]\AppData\Roaming\

I tried using the following relevance query but it’s throwing an error-
(exists file “xxx.txt” of folder “C:\Windows”) OR (exists file “xxx.txt” of folder “C:\Windows\SysWOW64”) OR (exists file “xxx.txt” of folder “C:\Users” & name of current user & “\AppData\Roaming”)

Could someone please help with this?

How about

exists file "xxx.txt" of (windows folder; system folder; folders "AppData\Roaming" of folders of folders "C:\Users")

The “system folder” inspector uses the 32-bit folder so should check \Windows\SysWOW64

2 Likes

This worked! Thank you so much! :slight_smile:

Sorry, 1 more question-
How about for the same file in a registry key value in “HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon”?