TmoDBNav 1.2

Last updated 12/08/04.

This is a picture of the TmoDBNav

At last, the moment arrives! (Drumroll.) I have gotten off my lazy you-know-what and put the Delphi 3 version here -- now that they've already released Delphi 4. This version is the same as the prior version (1.1), with two exceptions -- (1) it works in all 3 versions of Delphi, and (2) The new properties found in Delphi 3 are present in the TmoDBNav when used in Delphi 3.

(Sorry, if you're not a Delphi programmer, this thing won't do you a lick of good! Go back to my home page.)

If you've already downloaded it and have been having problems, check out the FAQ.

Ok, enough fanfare. Here's what you need:

Download Download TmoDBNav version 1.2 (Delphi 1, 2 and 3)
Download Download TmoDBNav version 1.1 (Delphi 1 and 2 only)

Please keep reading! There's more you need to know...

The zip file contains three files:

  • DbNav797.pas -- the source code. (This file is called DbNavNew.pas if you're using version 1.1.)
  • DbNav16.res -- 16-bit resource file for Delphi 1.0
  • DbNav32.res -- 32-bit resource file for Delphi 2.0

    The source is the same for both the 16- and 32-bit versions and has a compiler directive that tells it which resource file to use, depending on which version of Delphi you're using.

    By default, this component will be installed on the Samples page of your component palette. Click here if you need installation instructions.

    A help file will be available RSN. Monitor this site for information, or send me email at mmowens at panix dot com to be included on the update mailing list. Make your subject line read subscribe navigator.

    IF YOU'RE UPGRADING FROM VERSION 1.1 TO 1.2

    Since the component name hasn't changed, you will need to remove the old version before installing the new one. In addition, you will need to replace every reference to the DbNavNew unit with the reference to the unit called DbNav797 and rebuild all your code. Everything else is backward-compatible.

    To keep you going until the help file is available, you can

  • Read the source (always the best documentation IMO for any component)
  • Download Download NavDoc.zip (Word for Windows 7.0 format)
  • Download Download NavTxt.zip (Ascii text format)
  • Read the documentation online.

    For full information and the history of the making of this thing, and some samples of an integrated development approach describing how you can take full advantage of its features, check out my paper on it, which was on the 7th Annual Borland Developer's Conference CD. Please note that the code has changed somewhat since the writing of this paper, so you should always use the source from the file above for final reference.

    DISCLAIMER: I have provided these components and source code to the public free of charge. You accept these components AS IS without any representation or warranty of any kind, including but not limited to the warranty of merchantability or fitness for a particular purpose. You may not sell these components.

    Monitor this page for upgrades and enhancements, or get on the mailing list (see below).

    Comments and suggestions are welcome; tech support is not guaranteed, but will be generally available in a somewhat timely manner if I don't get too flooded with requests. In addition, I would appreciate it if you would send me your name if you use the navigator, so that I can maintain a usage count. If you want to send me money, that's okay (I spent many unpaid hours creating the thing), but like it says above, these components are free. My email address is: mmowens at panix dot com.

    Special thanks to:

  • Ed Jordan, for helping me solve the problem of more than 16 elements in the set of published properties, by providing sample code for the TmoNavBtnSwitches object.
  • Bill Morgenthein, for the set bookmark, goto bookmark and clear bookmark bitmaps (My drawing abilities rate -1 on a scale of 1 to 10).
  • Everyone at the Burgiss group, for using the navigator.
  • My mother, Terry Winter Owens (http://www.panix.com/~twowens/) for her tireless help in editing my conference papers.
  • Lizards, in general, for eating the bugs.

    TmoDBNav Brief Documentation

    The type names you are most likely to need in your code are as follows:
  • TmoNavBtns = the enumerated type of 18 buttons
  • TmoBtnSet = set of TmoNavBtns

    New Properties

  • property ConfirmDelete: Boolean; {Self-explanatory, I hope}
  • property SetMove: Integer default 10; {How many records to move at a time for PriorSet and NextSet buttons.}
  • property MaxSetMove: Integer default 100; {Use this if you are going to provide a way for the user to change the SetMove value, to prevent them from typing in too large a number.}
  • property ShowBookmarkMessage: Boolean; {If the user tries to goto a bookmark that is not in the current DataSet attached to the navigator, the navigator will try to do the goto anyway. If this property is true, the user will be warned and asked to confirm.}
  • property BookmarkMessage: String; {Use this to override the default goto bookmark warning message, which is: 'The bookmark you are trying to use belongs to a different data set than the one you are on.' + #13+ 'Continue anyway?'
  • property Orientation: TmoNavOrientation default noHorizontal; {The navigator can be displayed horizontally or vertically. Change to noVertical to display vertically.}

    New buttons:

  • Lookup Help (nbLookupHelp)
  • Locate (nbLocate)
  • Locate Next (nbLocateNext)
  • Set Bookmark (nbBkSet)
  • GotoBookmark (nbBkGoto)
  • Clear Bookmark (nbBkClear)

    The Lookup Help, Locate and Locate Next buttons are not visible by default, since you have to write code to make them do anything.

    Bookmark resources are, of course, released automatically when the navigator is destroyed.

    Changed Property

    The VisibleButtons property is a runtime-only property. At design time, it is replaced by the VisibleBtns property, which sets only one button at a time. (Interactively, on the Object Inspector, you will not notice much of a difference.) If you wish to enable or disable a specific button at runtime without changing the entire set, you can say (for example):

      moDBNav1.VisibleBtns[nbFirst].Visible := False;
    There is no performance advantage to doing this. This property had to be changed, because of a limit of 16 items in a design-time set.

    Delphi32

    With no changes to the source code, the TmoDBNav works as expected with Delphi 2.0; however the resource file format is different. The zip file contains resource files for both Delphi 1.0 (dbnav16.res) and Delphi 2.0 (dbnav32.res). You can not use the same copy simultaneously for both versions, because the resulting .dcu will be different.

    Planned changes for the future

  • Help file (in progress).
  • Implementation of the EnabledButtons property and SetButtonState method will change. These changes are guaranteed not to affect your code, but should make it work better and perhaps improve performance.
  • Property that allows you to put spaces between any buttons you want to. This could make the navigator appear as two, without actually having to have two.

    Possible changes

  • Property that allows you to change the button order.
  • Property that allows you to enable a default popup menu which allows the end user to change the Orientation and SetMove property values at runtime.
  • I am still trying to think of a way (that makes sense) to add hooks for menu items. This may not actually be possible to do without violating the object model.

    If there are any enhancements you would like to see added, please let me know.

    You were visitor #15007 to this page.

    [Top of this page] [Top of Documentation] [Maggie's Home Page]

    ©1996 Maggie Owens.