Microsoft Chat Server Development Guide

CustomCommand Sample

This extension implements a custom protocol command, Islocal, which determines if a user is connected to the local chat server.

Description

This sample demonstrates how to monitor commands sent by a user to the Chat Service. The Islocal command, which is implemented by this extension, displays whether the user is connected to the local chat server or to another chat server on the network. The syntax of the command is as follows:

Islocal nick

See the MangleTopic sample for an alternate approach to adding commands to the Chat Service.

Installation

This sample is built using Microsoft Visual Basic 5.0. You must have Microsoft Exchange Chat Service version 5.5 SP1 installed.

To install the sample:

  1. Run "regsvr32 CustomCommand.dll" from the command line to register the extension.
  2. Run regcatid.reg by double-clicking from Windows NT Explorer.
  3. Run Chat Service Manager.
  4. Select the local server. Right-click on Extensions, and select New, then Add Extension….
  5. Select "CustomCommandExtension.CustomCommand" from the list, and click OK.
  6. Restart the chat service.

Source Listing

The following files can be found in the chat documentation installation directory, in Samples\vb5\CustomCommand:

File Purpose
CustomCommand.cls Visual Basic class module
CustomCommand.dll Chat server extension DLL


© 1998 Microsoft Corporation. All rights reserved.