*===========================================================================
*
* PROGRAM-ID:   InGrid.vcx (Version 1.5a June 1999)
*
* AUTHOR:       Classy Components Inc. (www.ClassyComponents.com)
*                 by R. Scott Mackay (Scott@ClassyComponents.com)
*
* DISCLAIMER:	THIS COMPONENT IS SUBMITTED AS PUBLIC DOMAIN BY THE AUTHOR.
*
*               THIS PROGRAM IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
*               KIND, EITHER EXPRESSED OR IMPLIED.  IN NO EVENT WILL THE
*               AUTHOR BE LIABLE TO THE DEVELOPER/USER FOR ANY DAMAGES,
*               INCLUDING ANY LOST PROFITS, LOST SAVINGS OR OTHER
*               INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
*               USE OR INABILITY TO USE THIS PRODUCT.
*
* REVISIONS:    January 1996 RSM
*                 - Add preview in column header
*                 - Add support for views (i.e. LOCATE)
*				June 1999 RSM
*				  - Change alpha range to 32 - 128.
*
*               A 2.0 version of InGrid will be available soon (ETA Q3 1999).
*
* DESCRIPTION:	Ingrid is an incremental grid class that traps keystrokes
*               in the KeyPress event and incrementally searches through
*               the active cursor by Locating or Seeking (if indexes are
*               available).  One of the advanced features of this class is
*               the preview ability in the column header of the grid.
* 
*               NOTE: See the demo form for an example.
* 
*===========================================================================

To run the demo:

DO Demo

or 

DO FORM Demo



PEMs

cLocateExpression:  Locate expression to match against with
                    SearchString (Use this setting if no index
                    tags are available to seek against).
cOrderTag:          Index tag to control display order while on
                    current column (leave blank to use current tag).
cSeekTag:           Index tag to seek against with SearchString
                    (leave blank to use cOrderTag or current tag).
lInGridActive:      Flag to activate/deactivate incremental grid
                    keystroke trapping.
lSearchPreview:     Flag to activate/deactivate incremental grid
                    keystroke preview in column caption.

PROTECTED PEMs

[cHoldCaption]:     Hold column caption so that it can be restored.
[cSearchString]:    Search string to seek record with.
[KeySeek]:          InGrid seek method.
[lSeekMode]:        Flag to suppress GotFocus/LostFocus behavior
                    during seek operations.
[nHoldRecord]:      Hold/restore the current record in case the
                    seek fails.
[nLastPress]:       Last time a key was pressed.

GENERAL INSTRUCTIONS (refer to the VFP manuals for more info):

- Add the InGrid control to each grid column (the advantage of this
  is that each column can be setup to search on a different tag -
  the disadvantage is the extra work) to utilize the incremental
  search capabilities.

- Set the InGrid controls as the active controls in each column.

- Set the PEMs for the InGrid controls (if these are always the
  same for each column then consider creating a subclass).