Microsoft Indexing Service and ASP.NET

Getting Started

What is the Indexing Service?

Microsoft Indexing Service is a service that provides a means of quickly searching for files on the machine. The most familiar usage of the service is on web servers, where it provides the functionality behind site searches. It is built into Windows 2000 and 2003. It provides a straightforward way to index and search your web site.

Setting up the Indexing Service is explained at windowswebsolutions.com and will not be covered here.

Connecting to the Indexing Service

The Indexing Service exposes itself to the developer as as ADO.Net provider MSIDXS with the data source equal to the indexing catalog name. For example, the connection string used insearching this site is

Provider="MSIDXS";Data Source="idunno.org";

As with any other ADO.Net provider you use the connection string property of the System.Data.OleDb.OleDbConnection object.

using System.Data.OleDb;
protected OleDbConnection odbSearch;
odbSearch.ConnectionString=
  "Provider= \"MSIDXS\";Data Source=\"idunno.org\";"
odbSearch.Open();
//Query and process result
odbSearch.Close();

You can also use the connection string in Visual Studio by dragging and dropping an OleDbConnection onto your asp.net page and setting the ConnectionString property in the Properties tab.

You might also like...

Comments

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“PHP is a minor evil perpetrated and created by incompetent amateurs, whereas Perl is a great and insidious evil perpetrated by skilled but perverted professionals.” - Jon Ribbens