views:

407

answers:

4

Hello all,

I get this error when adding a reference to the Microsoft.Search.Interop.dll library in a new project that I created.

Microsoft.Search.Interop.dll is a library that provides some useful API to communicate with Windows Search. I use it in order to add a folder to the system indexer.

Did anybody else get this error, and if so, how should I go about solving it?

I'm using VS2010 RC on a Windows Server 2008 if that is important.

Thanks.

A: 

I have the same problem. Have you had any luck yet?

Regards Lasse

Lasse
A: 

Hello.

Yeah, I eventually figured it out. Apparently, there is a Microsoft.Search.Interop.dll file somewhere within the Windows Search SDK code examples.

You can get the code examples here, and just use the windows search to find it.

Hope it helps.

Cheers!

Andrei
+3  A: 

Go to the Properties window for Microsoft.Search.Interop and change the "Embed Interop Type" property to False.

Karin
A: 

I want to follow your answer:

'Go to the Properties window for Microsoft.Search.Interop and change the "Embed Interop Type" property to False.'

But I have no idea where is located that property. Any help?

Sorry but I'm a begginer programmer

Jose
I think that should be in the Visual Studio Properties Window, which is usually located in the bottom-right hand side of the Visual Studio development environment. If you can't see that "properties window", go to View -> Properties Window. There you will see a column dividing the name of the property (Embed Interop Type) and its value (True or False). You will have to change that property on the right side of the column.
Andrei
Thank you Andrei, I couldn't find that property because I didn't select the affected reference. Finally I realized of that. You gave me the clue.
Jose