A: 

Please provide an example of the search query, solution file and results returned. You haven't given enough information to figure out the problem.

Bryan
+1  A: 

If you do find in "Entire Solution", it also searches in any loaded files, even if they're already in the solution. This means that they'll be listed twice.

Perhaps this is your problem?

Roger Lipscombe
A: 

Are you searching "Entire Solution", or are you searching a directory and its subfolders? It looks like the latter. When this happens to me, it's usually due to this:

  • We're using SourceSafe.
  • We rename a directory or move a set of files from one directory to another.
  • Inadvertently, or from paranoia or whatever, we don't delete the files in the old directory.
  • When we do a Get Latest from SourceSafe, both the old and new set of files are gotten. The old files don't show up in VS, but they're still on my hard drive. So when I do a Find in Files, it looks in them too.

(But this may not be applicable, since it looks like your files have exactly the same directories.)

Kyralessa
A: 

Do you have any symbolic links to a directory/file within the same search scope? This could cause the file to be listed twice: once for the primary file, and once for the link to the file. Although from memory it should show the directory of the link for the 2nd occurrence, not the file pointed at by the link (and this is inconsistent with what is in your screenshot).

LeopardSkinPillBoxHat
+1  A: 

I use VS2003, but I get this exact result when I have the same source file in multiple projects. Are you sure you aren't searching more than one project?

Jim Buck
A: 

Try closing VS2008, renaming the file (USPostalApplciation.aspx and the code behind file too), then re-opening VS2008, refresh everything you can think of (project, solution, etc...) then try doing the search again.

Mark
This problem isn't specific to USPostalApplication.aspx. For this example, I just chose a search term that was only found in that page. If I search for "page_load" or some common term, every page (and there are over a 100) in the project will show up twice.
Aheho
A: 

I also had the same problem - which I just fixed. Make sure your web project does NOT have any virtual directories that point back to other areas of the site. Verify that VS2008 shows the same virtual directories (if any) that IIS has. If you have mis-pointed or mis-configured Virtual directories, it will cause a HUGE performance hit, search result replication, etc.

DaChew
+1  A: 

I had the same issue which was annoying. I just fixed it. What I've done is to change "Entire solution" to "current project" in "Look in" field when doing search. Then I noticed the result would not be doubled. After I switched back to "entire solution" the problem was gone.

A: 

I had a similar problem. VS would turn up find solution results from files I had loaded in the IDE just to view them and then closed again. So it would search through files that weren't even in the solution.

I scanned all files in the solution, but there was no reference to these phantom files stored anywhere. Finally I decided to scan the registry and found that they were stored in the MRU list. After deleting the MRU list entries, the expected behavior was restored.

Eric Hop