Click here to Skip to main content
12,956,606 members (54,099 online)
Click here to Skip to main content
Add your own
alternative version


18 bookmarked
Posted 19 Jun 2006

Indexing Service (CISVC) Reporting Script

, 19 Jun 2006 CPOL
Rate this:
Please Sign up or sign in to vote.
A VBScript to generate an HTML Report on the status/details of Indexing Service (CISVC) Catalogs


If you work with Indexing Service (CISVC) in Microsoft Windows 2000, you might be interested in having a periodic report emailed to you from the server.

At a previous job, I made extensive use of Indexing Service (CISVC) for keyword searching in the database. You might wonder why I didn't just use the SQL Full Text Indexing.. we did, but found the performance and controlling the process not adequate.


The key component used to access the indexing service is:

  • AdminIndexServer (ProgID: Microsoft.ISAdm)

This component provides access to a number of objects and methods that are used to query the status of the indexing service and its catalogs.

Objects, methods and properties used:

  • AdminIndexServer (ProgID: Microsoft.ISAdm)
    • GetCatalogByName (returns CatAdm object)
  • CatAdm
    • CatalogName (gets the current catalog name)
    • IsUpToDate
    • IsCatalogRunning
    • IsCatalogPaused
    • IsCatalogStopped
    • IndexSize
    • TotalDocumentCount
    • DocumentsToFilter
    • PctMergeComplete
    • QueryCount
    • StateInfo (* bitwise lookup, below)

I've chosen to only report on the status of specific index catalogs, but you can loop through all of the index catalogs by using the methods FindFirstCatalog and FindNextCatalog.

Note that the status of the catalog is given in such a way that you can use bitwise operations to get multiple statuses from the one return value. Here's a list of the constants I've used to get the status of the indexing service catalog:

  • CI_STATE_RECOVERING = 32 '0x20
  • CI_STATE_LOW_MEMORY = 128 '0x80
  • CI_STATE_HIGH_IO = 256 '0x100
  • CI_STATE_READ_ONLY = 1024 '0x400
  • CI_STATE_BATTERY_POWER = 2048 '0x800
  • CI_STATE_USER_ACTIVE = 4096 '0x1000
  • CI_STATE_STARTING = 8192 '0x2000
  • CI_STATE_READING_USNS = 16384 '0x4000

I hope this is useful for anyone having to deal with indexing service. I had many painful hours as I dealt with some quirk.

I think it's fairly straight forward to understand, I've tried to keep it simple (I'm sure someone has a witty quip to insert here... something about being simple ;-)).


  • 19th June, 2006: Initial post


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Web Developer
Canada Canada
Software developer by trade.. well I used to be, now I'm in that grey area where who knows what I do. But I still use software development in one way or another quite often. I actually work with osCommerce CRE Loaded for our online stores, and I have a couple tips on my website.

Finished my 'rocks for jocks' degree after 10+ years (physical geography). And I have to say that I use the knowledge and skills that I obtained while getting my degree every day... not! But if a glacier wanders through my neck of the woods I'm sure I'll be able answer everyone's questions.

Not that I'm a naturalist, but I love looking at and reading about interesting stuff in nature. For example, I took a photo of ants and aphids in a symbiotic relationship. You might be familiar with this relationship, but it's very cool.. though somewhat disturbing if you think of it.

And I should have been an engineer.. and not the train driving ones! Oh well, too late now.

You may also be interested in...

Comments and Discussions

-- There are no messages in this forum --
Permalink | Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.170525.1 | Last Updated 19 Jun 2006
Article Copyright 2006 by NewtonTroy
Everything else Copyright © CodeProject, 1999-2017
Layout: fixed | fluid