Properties

DBRichEdit surfaces a number of properties, some that are very familiar and others focused on the unique tasks of this component. The Alignment property affects the justification of the text contained with the control. The standard choices are offered Left-Justified., Right-justified, and Centered. serves the same purpose in this control as it does in the other BLOB-related components. By default, the contents of the BLOB field will be automatically displayed as the user scrolls through the...

Step Six Get the properties of the table

The cursor properties retrieved in this step include the table name, size, type, number of fields, and record buffer size. The properties are returned from the function DbiGetCursorProps Db iGetCursorProps (hCur, CursorProps) CursorProps is another structure defined in BDE.INT. It is a record with numerous fields used to gather all salient information about the cursor for your application's use. Note that the use of the word return is incorrect in the proper programming sense of a function...

Data Manipulation

The third aspect of the relational database model concerns itself with the manipulation of data. The model defines two categories of ope n tions that can be performed using the relations 14 Part I-The Relational Database 1. Assignment of relations to other relations 2. Manipulation of the data using eight defined operators Both categories are in reality intertwined. Data manipulation opera tions such as Select result in the selected data being placed into a new table. The eight relational...

Putting theBatch Move Component to Work

The BatchMove method and component are enormously useful addito your programming repertoire. For all of the additional functionality that the component offers, it is relatively simple to implement. The Copy Machine project that is built in the following steps wi experiment with the functions in two segments. The first will simply demonstrate the component and its copy mode. After this has been done, we will work with some of the error handling abilities of BatchMove. Chapter 5 Dotal Access with...

The DBEdit Component

DBEdit is the basic building block of any type of data entry application This component is limited to a single line of text and both displays and opens the dataset field to modification. DBEdit offers some degree of control over the formatting of the data being input and displayed using a number of property settings. Similar to the previous component, DBEdit is a data-aware version of the TEdit class. Review the data type that needs to be supported to determine if this is the appropriate...

Configuring the Borland Database Engine

The BDE is fully configurable through the use of the BDE Administrator, a utility that ships with the BDE. The utility accessible through a shortcut that will appear in the Windows Control Panel, provides a simple interface through which you can add and configure ODBC, standard, and SQL drivers, as well as configure the base options of the BDE. The Administrator's main window is shown in Figure 4.2. Figure 4.2 BDE Administrator 's main window Figure 4.2 BDE Administrator 's main window The BDE...

The Drop Index Statement

DROP INDEX table-name, index name PRIMARY You can use the DROP INDEX SQL statement to delete a primary or secondary index from an existing table. The notation used to perform this drop is different according to the table type and the type of index you are working with. To delete a Paradox primary key, the SQL statement will read A Paradox secondary index is deleted by using an identifier that appends the index name to the table name using dot notation dBASE primary or secondary indexes are...

The UpdateSQL Component TUpdateSQL

We discussed cached updates earlier in the context of the CachedUpdates property published by the dataset components. When cached updates are enabled, data is retrieved from a local or remote table and stored in local memory All operations that occur against the data work against this local dataset. When the modifications are written to the remote dataset, they are written as a large block rather than individually. This strategy serves to reduce transaction times and minimize network traffic...

The DBGrid Component

The DBGrid component is a workhorse among the data-aware controls Using a DBGrid, your application can display or manipulate a dataset in a familiar table-like form. The data is displayed and can be edited in an easily discernable rows-and-columns format. The columns represent the field definitions from the dataset with each row representing an individual record. Without any modification to its properties, the appearance of data in . the DBGrid component is largely defined by the properties of...

Normalization

Normalization is the process of decomposing relations to ensure maximum stability and minimal data redundancy. The process is one in which relations and their structures are refined in such a way that data is lost and no artificial structures are introduced. A fully 34 Part I The Relational Database normalized relation is one that most closely matches the guidelines o the relational model and exhibits correctness, consistency, stability, non-redundancy. A table is said to be in normal form when...

The Relational Model

The initial step to take in this foray is to establish clearly what the relational model is. Based on the certainty of mathematics, the defining rules for the relational model describe a system that provides consistent and accurate results in all conditions while maintaining the integrity of the data elements as a highest priority An important note to make at this point is that the relational model is not a blueprint for the physical implementation of data storage. How closely a particular...

Max Length

You will use the MaxLength property to limit the number of characters that can be entered through the DBMemo control. When the value of the property is set to 0, the default value, there are no limits in place. if a maximum length is entered, the underlying memo field is safe no text is truncated or lost. The limitation is meaningful only within the scope of the control itself. The text displayed in the DBMemo control is not constrained by the size of the component. Because of this it can...

The DBList Box Component

A list box control presents the application's user with a list of elements through which they can scroll and select one or more items. The DBListBox component is a data-aware version of the list box. The item that is selected from the list is entered into the database field that is associated with the control. A list box is used in interface situations in which you want to provide the user with a fixed number of selections from which to choose. The list can be built at design time using the...

OnChange

We have seen OnChange before but it is also an important facet of managing the Rich Edit component. When the event is fired, the text property of the control may have changed and the event handler is in a position to manage the change. The application should verify that actual change occurred by querying the Modified property Putting DBText, DBEdit, and DBRichEdit to Work Being able to simply view items in a database will not satisfy many clients. They keep wondering if there isn't some way...

Component Based Reports

Delphi supports component-based report building by including the QReport components on the same-named tab in the VCL. These components are provided by a third-party developer, QuSoft, and are well integrated because the entire set of components is written in Delphi. The component set gives the developer complete control over the page layout, all printer settings, and output. The next set of reports that we will examine will be built using these components. We'll begin by building a form report....

Second Normal Form NF

Second normal form further refines the database structures. To be in 2NF a table must in INF and all of the attributes must be fully depeiw ent upon the whole primary key. Every non-key attribute must be full dependent upon the primary key. The TRANSCRIPT relation in Figure 2.11 is probably not in 2NE The TRANSCRIPT table is in INF there are no repeating groups or multi-valued attributes. Your next step is to then consider the de pendency of the fields on the primary key of Student-ID + Class....

The Playen I

The best way to apply these conceptual tools is to work our way through an example. To do this we'll examine a common database application, the order entry system. This business model is easy to understand A company sells items to customers. The customers the company and provide their name and address and payment info mation, which the company retains for future reference. The custoflgl selects the items that they would like to purchase and orders the company, in turn, pulls the item from...

The DBText Component

The DBText component is a data-aware version of the standard Label control and is used to display the contents of a dataset field when they will not be edited. By its nature, the representation of the data is read-only, making this control an excellent choice for displaying the data with a high degree of security, A common use for DBText is to display a key value, such as a customer account number or ID, items that cannot be modified without disrupting the relational integrity of the database....

Value Checked

ValueChecked works in coordination with ValueUnchecked to specify the field values generated when the DBCheckBox control is modified,, The control works two ways based on the value in this property. If the value in the field of the dataset matches the value in this property, thfiU DBCheckBox appears checked. On the other hand, if the DBCheckBox checked by the user, the field's value is set to the string contained in-ValueChecked. The ValueChecked property can represent several values in a...

Documentation Format

Each entry in this reference will appear in the following format. The following entry shows an annotated example The function declaration is given in shorthand. This shows the calling sequence of the parameters. DbiActivateFilter ( hCursor, hFilter ) Each of the parameters is documented in a table that follows the function declaration. The handle to the filter to be applied. Part Ili-The Well-Rounded Application Part Ili-The Well-Rounded Application The functions all return a code indicating...

Want Tabs

The WantTabs property is an interesting by-product of the Windows world. The Tab key is commonly used for navigation purposes in an application and especially for moving among the fields of a dataset. A user attempting to place a tab character into the text of a DBMemo would find that he had suddenly exited the field with the keystroke. The WantTabs property can be set to True to allow the application to accept the tab characters literally in the DBMemo text. In this state, the user will be...

Database Explorer

The Database Explorer is a utility shipped with Delphi that incorporates a hierarchical database browser with data editing capabilities. The utility is also the gateway to the creation and manipulation of data dictionaries for Delphi datasets. A data dictionary is a special database that contains the attribute sets for field components. The tool ships in three different flavors with two different names, depending on the version of Delphi in use. The Desktop and Developer versions of Delphi...

Info

Complex calls into their application. This chapter will seek to develop this understanding while leaving the API discussion to later chapters. We will examine the architecture of the BDE first to surface the efficacy of the driver-based design. The drivers and the system of aliases critical to utilizing the engine follow, rounding out the engine discussion in abstract. Putting it to work is next on the agenda, so the utilities including the Database Desktop and the Database Explorer are...

Label Reports

Mailing or product labels are another common task for report developers. Labels are unique in their printing requirements because there are generally multiple instances of the label form on a single page. As with other designs, the QReport components handle the label task with aplomb. After the form report project, this will give you a little breather. The labels that will be designed are product labels such as those used in a warehouse to pick products from the shelves. The report we are...

Create Table

The DDL language set is more concise than the Data Manipulation Language but no less important. In fact, outside of database tools that take all of their direction through SQL statements, these statements are little used by programmers. Many programmers, not surprisingly, prefer to use interactive tools to create and manage their data objects. After this review, you might see these commands in a new light and realize opportunities for expanding your application development skill set. (...

Distribution of a BDEBased Application

When your application is written utilizing the features of the BDE, you must incorporate the necessary engine files into your installation rou. tine. A great majority of the database engine is redistributed with the application ex cutables, and Borland has specially licensed you to do so. Fortunately, the BDE can be either partially or completely redistributed, depending on the needs of your application. m example, your application may only support dBASE file types and therefore, You do not...

Putting Stored Procedures td Work

We will make use of the Local InterBase Server that ships with some versions of Delphi to explore the functioning of the StoredProd component and stored procedures in general. The project that we will build is called the Project Manager, and it works with the sample InterBase files in the IBLocal darabase. If you have not installed the LIBS, this database will not appear in the Database Explorer. Remember that the stored procedures are a part of the metadata of the database, so all of the...

Columnar Reports

The columnar report, a simple listing of rows, is a good place to start building reports. We will use that format to demonstrate the report creation process through simple coding in a procedure. The key to this approach to reporting is speed, not the number of features on the report. You can make this report as simple or as complicated as you desire. The format that we will use in laying out the report is shown below. Start the process by opening a new project. 1. On the form, place a Table and...

Loading the SQL Property from Another String List Object

The SQL property is a string list that can be loaded at design time or at run time. The design-time aspects of this task have been covered Partl f The Well-Rounded Application before, so this section is going to focus on loading and modifying the SQL property at run time. There are some common elements to the p cess regardless of the method chosen to load the string list. The first is that the Query must be closed before modifying the SQL strings. You might be tempted to utilize the known...

Report Analysis

In the process of designing reporting to meet the needs of your users, one question is a major determinant in the direction that you will follow Are you replacing an existing system or creating a new one If the latter is the case, your task is much simpler to accomplish. The system's users and the information that they desire from the application will define the output. They will not come to the design process with a predetermined bias towards a favorite report or a fixed way of doing things...

Step Two Open a database object

This step will connect to a database. The BDE accesses all tables through the context of a database. Single-tier applications will generally create an alias to a file system directory and utilize that as the database context. The function DbiOpenDatabase is used to open a database dbiREAOWRITE, dbiOPENSHAREO, nil, 0, nil, nil, hOB This sample function call opens the DBDEMOS database, assuming that it has been properly configured within the BDE. The second parameter, STANDARD in this case,...

The Data Source Component TData Source

The DataSource component is the pipeline between a dataset and the data-aware components. This intermediary component is required any time that data-aware components and dataset components are to be utilized on a form. The DataSource component requires a matching DataSet component in every case. The DataSource control also enables the linking of datasets in master-detail parent-child relationships. The DataSource component surfaces a limited number of published properties for use at design or...

Environmental Functions

The BDE environment functions return information pertaining to the application environment. This includes the supported table, field, and index types or available types. In addition, tasks such as loading a specific driver or initializing the engine fall into this category. DbiDeleteAlias DbiDeleteDriver DbiDllExit DbiExit

Database Explorer Interface

The appearance of the Explorer closely matches the format seen in the BDE Administrator. Figure 4.16 shows the dual-paned window used for all actions in the Explorer. The left pane contains two tabs the Databases tab listing all database aliases defined to the BDE and the Dictionary tab showing the contents of the data dictionaries that have been defined. ffi- CflSS CRSYB -jS dBASE Fies DBBOEMOS S Tables ffi- CflSS CRSYB -jS dBASE Fies DBBOEMOS S Tables SHU neighbor.dbl -H REGISTER.db 0 Fields...

Form Reports

Form reports use more of a free-form layout when presenting data to the user. Rather than list the data rows, the data is presented in different areas of the page for clarity and readability purposes. A good example-krf this type of report is an invoice. The top of an invoice will usually cor the customer's name and address, contact, and telephone information. Below that, the invoiced items are listed and summarized, usually ending with an amount owed. The next project creates a form report...

Local SQL

There are a number of items that are specific to Local SQL that should be mentioned prior to discussing the statement syntax. The sections that follow highlight the syntax rules that are specific to the formulation of the SQL statements using the Local SQL implementation. When developing in a multi-tier environment, refer to the other product documentation to determine its specific requirements. Local SQL is enhanced to handle multiple-word table names. Table names can include the full path and...

Alternatives to the Borland Database Engine

Among the advantages of the separation of the BDE from the internals of Borland's development products is the freedom of choice. The open architecture of the Delphi development environment allows you to replace the database engine with other, sometimes better, products, Why would you want to consider this avenue The reason that is most often listed supporting the replacement of the BDE is size and overhead. When you create a Delphi application and prepare it for distribution, you must also...

Packing Paradox Tables

Paradox tables do not need to be packed as often as dBASE tables. When a record is deleted from a Paradox table, that space is made immediately available to new entries. The situation may arise where a large number of records are deleted all at once, leaving a lot of unused space in the table that will not be immediately filled. To pack Paradox tables you are required to use a different function, DbiDoRestructure. Working with Paradox tables requires that you use a structure called CRTblDesc, a...

The DBImage Component

It's a graphical world out there, and Delphi's darabase supporr for a graphics object is second to none. Nearly all database products sup ported by the BDE support the inclusion of bitmapped graphics in BLOB Binary Large OBject data fields within the table. BLOBs are not Chapter B-Delphi's Data-Aware Components limited to being containers for graphics but this is one of their most common uses. If a field type is supported by the BDE you can count ofl Delphi offering a component to work with...

The Borlandu Daiabase Enmne an the Database UtteT I

He Borland Database Engine BDE is the motor that drives all of the database functionality in Delphi as well as C Builder, Visual dBASE, and Corel's Paradox. Originally brought to life as IDAPI Independent Database Application Programming Interface , an open database connectivity product, its popularity in this context has been usurped in recent years by ODBC. Borland's decision to focus the engine back on its core tasks has been very beneficial to the BDE and developers who utilize it. The...

Dbi AnsiToNative LdObj Native Str Ansi Str Len bData Loss

Pointer to the language driver object returned from calling DbiGetLdObj. The translations string. The client buffer containing ANSI data. Specifies the length of the buffer to convert. If 0, a null-terminated string is assumed. If the result is True. the ANSI string cannot map to a character in the native character set. Appendix A BDE API Quick Reference DbiAnsiToNative functions as a translator of strings from ANSI to the language driver's native character set. DbiAppendRecord hCursor,...

The Table Component TTable

The Table component is generally the first data access control that you will pair with a DataSource control to construct a database application. It has been designed to provide uniform access and navigability to each row in the table types supported by the BDE regardless of the underlying rules of the dataset source. Despite the wide range of properties, it can be quite simple to use. Place a table component on a form, set the Database and Table properties to point to the relation you want to...

Hide Selection

The DBRichEdit component allows selection of blocks of text either with the mouse or through standard Windows keyboard methods and_ marks the text in the standard fashion with a colored block highlight it. Depending on the setting in the HideSelection property this selection-marking may remain or disappear when the focus shifts to another control. Setting this property to True will cause the selection marking to be visible only when the focus remains on this component. When the visual cue of...

Index Functions

These functions create or drop indexes or return information about a specified index. DbiAddlndex DbiCloselndex DbiCompareKeys DbiDeletelndex DbiExtractKey DbiGetlndexDesc DbiGetlndexDescs DbiGetlndexForField DbiGetlndexSeqNo DbiGetlndexTypeDesc DbiOpenlndex DbiRegenlndex DbiRegenlndexes DbiSwitchToIndex The BDE functions listed acquire or release record or table locks or return information about a lock's status. Part Ill-The Well-Rounded Application

Step Eight Position the record point on the appropriate record

This step introduces some new vernacular to the developer's vocabulary in the use of the word crack. Cracks are the imaginary lines that separate each record in a database. Using this terminology allows you to envision the record pointer being positioned before the first record in a table or after the last. You can also place it between two records, committed to neither. Use the DbiSetToBegin function to set the pointer to the crack before the first record 282 Part III The Well-Rounded...

Key Properties

The properties that will receive our attention here are those that are unique requirements of the image orientation of the control. The value of this property determines whether or not the contents of the graphic BLOB will be automatically displayed. When set to True, each time the contents of the BLOB field change, such as when the user browses from row to row in a dataset, it is automatically redrawn. Depending on the size of the image, this continual redisplay of the graphics could become a...

Key Pr operties

The lookup controls take a little study to integrate properly into your application, and the key to understanding them is to be knowledgeable about the settings for the properties. The KeyField property identifies the field from the source listed in the ListS ource property that must match the value of the field specified in DataField. This links the ListSource dataset to the DataSource. The fields do not need to share a name but must have the same values. The field specified in KeyField is not...

The Database Component TDatabase

Every Delphi database connection is encapsulated by a Database corn-ponent, whether or not you actually place one in your project. The Database component is responsible for providing all of the connection information from the database to your application. An automatically generated database component is instantiated for each BDE application- to encapsulate the connection. The most important task of the Database component is to provide your application with information about the type and...

Creating the Table at Design Time

One word of warning before approaching this task You must be well versed in the TTable class before putting this information to work in a production situation. You are going to be defining every aspect of a Table without the benefit of the Desktop, which masks a lot of this from you and automates many operations. The properties, methods, and events of the Dataset object should be reviewed to ensure that all of the values that you are going to define are appropriate for the object that you want...

Along Came Codd

In 1968, while working as a researcher for IBM, Dr. E.E Codd began to examine the possibility of applying the uniformity and consistency of mathematics to the undisciplined field of database management. His research resulted in the now-classic paper, 'A Relational Model of Data for Large Shared Data Banks, which was published in 1970 and Chapter I Introduction to the Relational Database H 9 This first property is of primary importance, as it sets the stage for many of the later properties and...

Entries in Each Column are from the Same Domain

A domain is the defined set of values from which the data in a column can be drawn. This pool of values describes the entire range of acceptable data elements. For example, the domain of the column Employee-ID is the range of valid employee ID numbers. Items not belonging to that collection of values, such as the employee's last name or an ID number beyond or below the valid range, fall outside of the domain for that column. With a domain for each column defined, the user is rewarded with...

Addressing the SQL String List Directly

After seeing the two alternative methods for adding the SQL sratements to the Query component's SQL property, this section might seem a bit anticlimactic. There is no great mystery to loading the property using the Add method. The code block below shows that the process is straightforward with Query 1 do begin Close SQL.Clear This simplified method lends itself well to taking a building block approach to the construction of the SQL sentence. To show what this means, consider the same statement...

The DBChart Component

The DBChart control is another of Delphi's hidden gems that is available to lend additional features to your application. The class is derived from the TChart class and is extended to utilize a dataset for the source of its data series. Using the columns of a dataset for its source, the chart becomes a dynamic display that is updated as the dataset is modified. You have a wide variety of chart type options to choose from and all of the parameters of the display can be controlled within an...

Entity Integrity

The first rule is simply a repeat of the earlier structure requirement that each row in a table be unique. The entity integrity rule requires that no part of the primary key of a table be allowed to accept null values. Blank data fields do not lend themselves to an adequate description of the row, so requiring data elements in the column or columns that make up the key to the row makes perfect sense. Requiring that the key for each row be unique fulfills the mission of the relational model....

OnResize Request

This event fires when the edit control attempts to resize to accommodate expanding or contracting text. The application then has the opportunity to adjust or retain the edit window size and manipulate-necessary user interface elements to handle the text. The OnSaveClipboard event is fired when Windows is in the middle of transferring data to the clipboard and the user is attempting to destroy the edit window that is the source of the data. The event handler can be written to delay the window...

Configuring a Standard Database

A standard database, which includes the Paradox, dBASE, ASCII, or FoxPro drivers, will expose a small set of configurable options. Exploring the standard database configuration options is best performed by creating a new object. To add a new alias 1. Click on Object New from the menu or right-click on the Databases tab and select New. 2. The New Database Alias dialog will be displayed from which the database driver is selected. This option determines the type of alias that will be created....

Dbi Exit

Part III The We I-Rounded Application Part III The We I-Rounded Application DbiExit disconnects the application from BDE. It releases all resources allocated by the client application and should be the last DBI BDE call made by the client application. DbiExtractKey hCursor, pRecBuf, pKeyBuf Pointer to the record buffer that contains the key to be extracted. The variable to receive the key value. The function DbiExtractKey gets the key value for the current record from either the cursor or the...

Dbi CloseDatabase hDb

Closes the specified database and any associated The function DbiCloseFieldXlt closes a field translation object. DbiCloselndex hCursor, szlndexName, ilndexld The cursor handle. A pointer to the index name. Currently not used. The function DbiCloselndex closes the specified index for the cursor. DbiCloseSession closes the session and frees all resources associated with it including database handles, cursor, table-level locks, and record-level locks. DbiCompareBookMarks hCur, pBookMark I,...

DBNavigator Events

Two events are native to the DBNavigator class, both allowing you to trap the push of one of its buttons and initiate any special processing that you want to implement. The BeforeAction fires when a button on the navigator is clicked but immediately before the default action for that particular button is executed. is fired when any type of click event occurs. This includes a mouse click, the spacebar being pressed when the navigator has focus, or the Btn Click method being called. The default...

Cursor Functions

These functions either perform an action on a cursor, such as positioning, linking, or creating and closing a cursor, or return information about a cursor. DbiApplyDelayedUpdates DbiBeginDelayedUpdates DbiBeginLinkMode DbiCloneCursor 294 Part Ili-The Well-Rounded Application

Alphabetic Function Listing

DbiAcqPersistTableLock hDb, szTableName, szDriverType Reference to the table's driver type. DbiAcqPersistTableLock acquires an exclusive, persistent table lock that prevents other users from accessing the table or creating one of the same name. DbiAcqTableLock hCursor, eLockType Specifies the type of table lock required. DbiAcqTableLock allows the user to acquire a table-level lock that can prevent other users from updating a table. DbiActivateFilter hCursor, hFilter The handle to the filter to...

Session Functions

These functions return information about a session or perform session-related tasks. Chapter 9-The Borland Database Engine API This list of functions performs tasks related to the tables. Some will return information about a table such as lock status, a list of referential integrity links, or the indexes open on the table. Functions that perfon 0 table-wide tasks such as copying and deleting are also included. DbiCopyTable DbiCreatelnMemTable DbiCreateTable DbiCreateTempTable DbiDeleteTable...

The DBRadio Group Component

The DBRadioGroup component is a data-aware version of the RadioGroup control. Similar to the data-aware list components, it presents the user with a limited choice of selections for a data field. The user selects the value that they want to enter for the field by select ing one of a group of radio buttons. A radio button interface should only be used in situations where the number of choices is very limited. The mutually exclusive nature and default selection options of these controls require...

First Normiai Form INF

To be in first normal form, a relation must have no repeating groups or multi-valued attributes. The class and grade fields in Figure 2.10 area good example of a non-relational design. Each student record maintains the names of up to four classes and grades. To be a relational table, each attribute, or field, must represent a unique, discrete fact about the entity. The fields in the example relations represent duplication of the data. It is a simple matter to reduce this relation to first...

The DBLookup ListBox and DBLookup ComboBox Components

This pair of components is so similar in nature that it makes sense to discuss them in tandem. DBLookupListBox and DBLookupComboBox are data-aware controls that build their display items lists from either of two sources The data can come from a lookup field defined in a dataset or from a secondary data source altogether. The controls present the user with a limited list of choices with which to fill the associated dataset field. Physically, these controls are the same as their non-lookup...

The DBRich Edit Component

The DBRichEdit component is a data-aware control that can display formatted text stored in BLOB fields. Rich Text describes text fields that support the formatting of individual characters, words, and paragraphs. Text searching and printing functions are supported by Rich Text controls and by default they support the following types of formatting Font attributes such as typeface, size, color, etc. Text alignment, tabs, indentation, and list numbering The conversion of Rich Text to plain text...

The Query Component TQuery

The Query component is similar in nature to the Table component it provides a method of accessing table data from a wide variety of sources and making it available to the application. What makes it different from the table is that it uses SQL SELECT statements to build the dataset that it displays. The property list for the Query component is detailed in Figure 5.4 and as you will notice, it looks remarkably similar to the property set of the Table. This, of course, is because both the Table...

The DBMemo Component

The DBMemo component is the brother to the DBImage data-aware control it displays BLOB data from the associated database field. The BLOB data supported by this control is large blocks of text in Memo fields. Memo data is free-form text in which the user has the benefit of a variable length field. With no constraint placed on the maximum size of the field, the user is able to maintain lengthy collections of text, updating it as necessary. The text contained in the field can be subject to a...

TData Source Events

There are three event handlers exposed by the TDataSource class Each of the event handlers fires on a change in the dataset to which it is connected. It does not reflect any change in the DataSource the control remains a simple intermediary The OnDataChange event is triggered by the cursor moving to the next or previous record any method that results in a change in the cursor position will trigger this event. This event is especially useful for ma' ally synchronizing components. Whenever the...

OnCol Enter

The OnColEnter event fires when the focus shifts into a new cell in the grid including navigation by keyboard or mouse click. OnColExit events fire when the focus is in the process of leaving the cell. This event fires when dragging with the mouse moves a column. OnColumnMoved occurs just after the column has been moved. This event is provided to give the application an opportunity to repaint a cell. The OnEditButtonClick event fires when the ellipses button on a drop-down or pick list column...