TDB2Web - Technical reference


Memo treatment

Memos (TMemoField) are written to separate files and are accessed from within the table by a link and/or or mapped image.

Line-feeds (10d) within the memo are interpreted as the end of the current paragraph.

File name's extension is .HTM

We heard, that still some people work with operating systems that require old-style file names (like DOS and NetWare), so we are forced to use 8-character filenames. This causes some general output restrictions.

An existing memo for a record and/or table-row will be marked with a picture (default is Attach.jpg), otherwise (if there is no memo) a simple hyphen appears.

The memo-files are located in the specified ExportDir.


Graphics treatment

Like memos, graphics (stored in a TBlobField or a TGraphicField) are written to separate files while exporting, with the extension .JPG, though.

To be INet- and/or browser-compatible, graphics will be converted to JPEG-format.

File naming conventions, location and access from within the table is equal to memos, except that the default image for a JPEG is Image.jpg instead of Attach.jpg.

Import notice:

There are some limits and restrictions with respect to graphics:

  1. Since xBase-tables and most of ODBC-sources do not provide specialized graphic-BLOBs, both of the field types TGraphicField and TBlobField are assumed containing graphical information.

  2. If you intent to store picture formats different from BMP to the BLOB, you should add an alphanumeric field named GRFORMAT (3 digits) to the database in order to enable TDB2Web to recognize the format of the graphic stored in the BLOB.

    The field's content should be the file extension of the image, f.e. JPG for JPEGs, PCX for ZSoft pixels, etc. The field-entries are not case sensitive.

    By default TDB2Web assumes the BMP-format. If it is not, you will encouter an error.

TDB2Web - Supported graphic formats

Format Color mode Supported
BMP True color (RGB) Yes
BMP Indexed color Yes
JPEG True color (RGB) Yes
GIF Indexed color (Yes; see note below)
PCX True color (RGB) Yes
PCX Indexed color Yes
TGA True color (RGB) Yes
TGA Indexed color No
TIFF in general No

Remarks:


Numerics treatment

Float fields

Currency fields

Currency fields are converted using the FormatToStrF-function with two decimals.

Other

All other numeric types appear simply as is.


Column selection and definition file

Main purpose of the columns definition dialogue is defining the contents of the output table.

The content (i.e. the selected fields along with their properties) is stored in a file which name bases on the dataset's name to which it belongs to. The name of this file is automatically set and expected when entering this dialogue, so do not rename it!

Important: In difference to the exported files this file is expected to be a local one and therefore has no DOS-restrictions!

Usage

Simply select one of the Available Fields and drag it to the Currently selected-grid. The newly placed field will appear on the right side of the grid.

Within the grid you can move the columns as usual to any position you like.

You remove a column by pressing [Ctrl]+[Del]. Alternatively you can click on the right mouse button and see what happens.

To access the attributes just click on either a grid's column or one of the Available fields.

Setup available fields

The Available fields list shows all available fields of the given dataset.
The meaning of available depends on the given datasource:

Alter the definition file

As mentioned above, the currently selected columns (as they are in the Currently selected-grid) are stored along with their properties in a file. The file's name equals the dataset's name plus the extension .CDF and is placed in the home directory of the application.

It is a plain ASCII-file. So, if you do not want the user to change the selection you have the chance to alter and/or prepare it with any text editor.

Warning: The parser seems to work fine, you should be careful, though!

Since this file is an SGML-based document it requires some rules. These rules are embedded in the program and cannot be modified.

Valuable elements

ElementStateRemark
DATASETRequiredMust be first element
Attribute required: NAME, Value: Name of the dataset
COLUMNRequiredMust follow DATASET-element
FIELDNAMERequiredMust follow COLUMN-element
HALIGNOptional-
VALIGNOptional-
HEADEROptional-
ANCHORNAMEOptional-
WRAPOptionalIf set, must be last element

Switching the optional elements may produce unpredictable results.

This is a short example of how a Column Definition File looks like:

<!DOCTYPE ColumnDefinitionFile SYSTEM>
<!-- Creator: _dbp_test -->
<!-- Creation date: 01.08.97 10:07:15 -->
<!-- This is an automatically generated file.
     It will be read and overwritten.
     Do Not Edit! -->
<DATASET NAME=Table1>                     <-- Required -->
  <COLUMN>                                <-- Required -->
    <FIELDNAME>Species No</FIELDNAME>     <-- Required -->
    <HALIGN>Right</HALIGN>                <-- Implied -->
    <VALIGN>Top</VALIGN>                  <-- Implied -->
    <HEADER>Species No</HEADER>           <-- Implied -->
    <ANCHORNAME>mailto</ANCHORNAME>       <-- Implied -->
    <WRAP>NOWRAP</WRAP>                   <-- Implied -->
  </COLUMN>                               <-- Required -->
</DATASET>                                <-- Required -->


General file naming and Output restrictions


Error handling

All errors are handled within TDB2Web; no further error handling is required.


Differences between Navigator 4.0 and IE 3.0

We learned about three major differences between Navigator 4.0 and Internet Explorer 3.0 that are meaningful to TDB2Web's functionality:

Item Supported by
NavigatorExplorer
Table alignment Yes No
Table caption alignment Yes No
Separate frames and rules No Yes

Another minor difference is that IE underlies the table's title with the background color, in Navigator it is body's background.


Known problems