home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 December / Chip_2001-12_cd1.bin / zkuste / delphi / kolekce / d3456 / ALEXSOFT.ZIP / _READ.ME next >
Encoding:
Text File  |  2001-09-04  |  8.3 KB  |  169 lines

  1. AlexSoft Component Library (freeware edition).
  2. Author - Alex Rabichooc.
  3. a_rabichooc@yahoo.com
  4. alex@carmez.mldnet.com
  5.  
  6.    This package was designed for easier development of clients for database
  7. applications.
  8.    It was created in 1998 for personal purposes, therefore any Help or
  9. documentation is missing.
  10.    I decided to publish it for public use in slightly simplified edition. If
  11. you will find some bugs in this edition, please let me know - I didn't check
  12. this edition for bugs.
  13.    I will describe only key properties of my components. For more information
  14. see source code.
  15.  
  16. 1)TRaDBedit - Dbedit/DbLookup/DbImage/DbMemo(depending on Field's type) Field
  17. with Text Label.
  18.  properties:
  19.    published
  20.     DataSource, DataField - DataSource and Field.FieldName.
  21.     EditKind (ekCommon, ekView, ekControl) - type of the field.
  22.       - ekCommon - ordinary field,
  23.       - ekView - non edited field (like TDBText)
  24.       - ekControl - control field. Depending on the Fields type, clicking on the
  25.       button (by default) will result following action(see DoButtonClick method):
  26.       * if Field.DataType = ftMemo, ftFmtMemo - Start Rich text editor for the
  27.         Field
  28.       * ftGraphic, ftTypedBinary, ftBlob - Start Image Editor for the Field
  29.         (in this edition it highly simplified)
  30.       * ftDataSet - Start Edit/View form for the NestedDataSet
  31.       * ftDate, ftDateTime - Start Calendar form.
  32.       * If the Field is Lookup field or it is key field for another lookup
  33.         field, by clicking on the button you will launch Editor/Viewer form for
  34.         the corresponding Lookup DataSet.
  35.       To override the default click action, you can write OnButtonClick event
  36.       handler.
  37.     ShowBLOB - for BLOBs. If True, Memo or Image will be visible in the TRaDBedit.
  38.    public
  39.       Field: TField - pointer to the linked TField.
  40.       Glyph, NumGlyphs - for the button
  41.       ReadOnly - if true, user can't change the value of the field.
  42.  
  43.  events:
  44.     OnButtonClick - occurs when the user clicks the button (default action -
  45.       DoEditButtonClick in unit dbtools)
  46.     OnReplaceField - occurs when the user closes Lookup DataSet Editor/Viewer
  47.       Form and replaces the value of the key field with the current value of
  48.       lookup key field (default action - ReplaceField in unit dbtools)
  49.  
  50. 2)TRaDBBox - ScrollBox, containing TRaDBedits (it can also contain other
  51. controls) - like TDBCtrlGrid.
  52.  properties:
  53.    DataSource - points to the linked DataSource
  54.    CreateMode (cmAuto, cmManual) - creation mode of TRaDBedit components
  55.       - cmAuto - creates it automatically from DataSource.DataSet
  56.       - cmManual - user can add/delete/modify TRaDBedits (and other controls)
  57.         manually.
  58.    Orientation (orVertical, orHorizontal)- disposition of TRaDBedits when
  59.       CreateMode = cmAuto.
  60.    ReadOnly - if true, user can't edit the linked DataSet.
  61.    ShowBlobs - the same as for TRaDBedit
  62.    AllowMove, AllowDelete, AllowInsert - determines ability of movement trough
  63.       DataSet, deleting from it and inserting new rows into it using keyboard.
  64.    ConfirmDelete - when true, a message box appears, asking for confirmation,
  65.       when the user trying to delete a row from DataSet using keyboard.
  66.  
  67.  navigate Keys:
  68.    Ctrl-F1: Click to TRaDBedit button
  69.    LEFT,RIGHT,UP,DOWN,TAB,SHIFT-TAB,ENTER: Field movement
  70.    PgDn,PgUp,Ctrl-PgDn,Ctrl-PgUp: Record movement
  71.    F2: Changing edit mode
  72.    INSERT, Ctrl-INSERT: Append, Insert into DataSet.
  73.    F8: Delete from DataSet.
  74.  
  75. 3) TRaDBGrid - like TDBGrid. Automatically determines whether a column should
  76.   have ButtonStyle=cbsEllipsis using same criteria (and with the same effect) as
  77.   TRaDBedit.EditKind = ekControl. Navigation was changed - added keys
  78.   Ctrl-F1, Enter, F8 (same actions as in TRaDBBox)
  79.  properties:
  80.    RedMinus - determines whether negative values of numeric data fields are drawn
  81.       in red color.
  82.    VisibleColCount, VisibleRowCount - the number of completely visible columns and
  83.       rows.
  84.  
  85.  events:
  86.    OnReplaceField - the same as in TRaDBedit.
  87.  
  88. 4) TRaDBPanel - aggregate of TRaDBGrid and TRaDBBox - suitable for Master-Detail.
  89.  properties:
  90.    DataSource - linked DataSource
  91.    PanelStyle (psAuto, psBox, psGrid) - style of panel.
  92.       - psBox - Panel looks like TRaDBBox
  93.       - psGrid - like TRaDBGrid
  94.       - psAuto - if DataSource.DataSet is Detail DataSet for Master-Detail
  95.         relationship, then in the panel both TRaDBBox(Master) and
  96.         TRaDBGrid(Detail) are visible, otherwise panel looks like TRaDBGrid.
  97.    Box - points to TRaDBBox
  98.    Grid - points to TRaDBGrid
  99.    BoxFields - collection of TRaDBedits in TRaDBPanel.Box.
  100.    GridColumns - TRaDBPanel.Grid.Columns.
  101.    BoxHeight - for Master-Detail (when PanelStyle=psAuto), Box's height.  For
  102.       automatic calculation of Box's height, set BoxHeight = -1.
  103.    CloseOnEscape - when true, pressing Esc key will close parent form.
  104.  
  105.  navigation keys are the same as in TRaDBBox and TRaDBGrid +
  106.    Ctrl-1: Move to first level (Box)
  107.    Ctrl-2: Move to second level (Grid)
  108.    Esc - When CloseOnEscape = true - closes parent form.
  109.  
  110. 5) TRaDBSearch - searches field values in the linked DataSet.(It performs
  111. search on the client side, not on the server side (!!!) so only in rows, which
  112. currently exist in the DataSet)
  113.  properties:
  114.    DataSet - linked DataSet.
  115.    SearchKind(skNormal, skExtended, skContext) - determines search kind:
  116.       ordinary search, extended and context search. User can define fields (by
  117.       double clicking on the component in designtime). To Start search in runtime,
  118.       call method
  119.       Execute(DefaultField: TField): Boolean;
  120.       where DataField - Dataset's field which is used for searching (or nil).
  121.  
  122. 6)TRaDBNavigator - like TDBNavigator. Added search button.
  123.  properties:
  124.    DataSourceAuto - if true then Navigator is linked to the DataSet of current
  125.       active data aware control (if exists).
  126.    SearchComponent - points to TRaDBSearch component (can be nil).
  127.    DefaultAction - if defined event handler OnClick, then this property
  128.       determines whether default action should be done when the user clicks
  129.       navigator button (default action - DoDefaultClick(buttonIndex));
  130.  
  131. 7)TRaDBInsert - CheckBox.
  132.  If RaDBInsert.Checked = true then when user inserts rows into the linked
  133. DataSet, Values for all dataset fields are taken from the current record.
  134.  
  135. 8)TRaTable, TRaQuery, TRaStoredProc, TRaClientDataSet - like TTable, TQuery,
  136. TStoredProc, TClientDataSet
  137.  new properties:
  138.    FormCaption, FormClassName, ModalForm, FreeOnClose. This properties are
  139.       related to the Form, which is a Editor/Viewer form to the DataSet. When
  140.       the user presses Ctrl-F1 (see TRaDBEdit) or clicks TRaDBEdit button,
  141.       Editor/Viewer form for the Lookup Dataset is launched. If the property
  142.       FormClassName is not defined, this form is TDefaultForm (unit DBForms).
  143.       However in many cases user needs more complex forms. To do this you need:
  144.         a) Design such Form
  145.         b) In Delphi source code editor in "uses" clause add unit DBForms
  146.         c) In Delphi source code editor change the declaration. This form
  147.            should inherit from TDBForm instead of TForm:
  148.          Ex: TmyForm1 = class(TDBForm)
  149.         d) Register the class of this form
  150.          Ex: RegisterClass(TmyForm1)
  151.          You can do this in "initialization" section of the unit.
  152.         e) Set property FormClassName of corresponding DataSet to this class
  153.          Ex:FormClassName = TmyForm1
  154.         f) Set property FormCaption of corresponding DataSet to form's caption
  155.      If all of this steps is done then the Editor/Viewer form for this
  156.      DataSet will be TmyForm1 instead of TDefaultForm.
  157.    ModalForm determines whether DataSet form is modal.
  158.    FreeOnClose determines whether DataSet form will be destroyed after closing.
  159.  
  160.  To launch manually Dataset form in runtime call function:
  161. function InitDBForm(DataSet:TDataSet; Field:TField; AOwner:TComponent): Integer;
  162. where DataSet - DataSet, Field - control field (Lookup or key field for lookup
  163. field) or nil.
  164. Return value - if Form is a modal form - ModalResult, otherwise 0.
  165.  
  166. This package also contains some QuickReport components designed for printing on
  167. matrix printers using built-in fonts (ASCII printers). If it is interesting for you
  168. I will describe them by e-mail.
  169.