Overview | Module | Use | Devguide | Index

Included Services | Exported Interfaces | Properties' Summary | Properties' Details

:: com :: sun :: star :: form :: component ::
service DataForm
Description This service specifies a form which is connected to a database and displays the results of SQL queries. It provides the possiblity of adding new data records, modifying existing ones, or deleting them. A database form is a special kind of enhanced database row set which provides all information for displaying the data and has more possibilities for configuring the data manipulation.

Included Services
::com::sun::star::sdb::RowSet | is a client side RowSet, which use retrieves is data based on a database table, a query or a SQL command or by a rowset reader, who mustn't support SQL. The connection of the rowset is typically a named DataSource or a DataAccess component or a previous instanciated connection.
Form | This service specifies a form which is a group of FormComponents.

Exported Interfaces
::com::sun::star::form::XReset | Description is used to initialize a data row which should be inserted. TODO: define the conditions under which forms and controls are (or should be) reset
::com::sun::star::form::XLoadable | Description used to load/unload the form Loading a form is basically the same as executing the underlying row set. In fact, all the functionality of this interface could be simulated by using setting some properties manually, XRowSet::execute , moving the row set cursor and so on. One main difference between XLoadable::load and XRowSet::execute is that if you use the former, the row set is positioned on the first record, while in the latter case it is position before the it.
::com::sun::star::sdb::XCompletedExecution | Description can be used to allow an interaction handler to supply missing data during a load process. If data is needed during loading a form, then this is usually obtained via broadcaster-listener mechanisms. An example for this (and currently the only one) are parameter values. However, if you use this method, you can pass an interaction handler which should supply these additional data. See also ::com::sun::star::sdb::InteractionHandler
::com::sun::star::form::XDatabaseParameterBroadcaster | Description can be used for filling parameters. You can add your component as ::com::sun::star::form::XDatabaseParameterListener to a form to get notified whenever the form needs parameter values to be filled in In a first approach, the form tries to fill any parameters from it's master-detail relation (if any). All values which can't be filled are then passed to all listeners, which can fill them by their own choice. This is sligtly changed if the form is loaded using the ::com::sun::star::sdb::XCompletedExecution::connectWithCompletion method. In this case, the parameters are obtained from the interaction handler, not from the listeners See also XCompletedExecution See also MasterFields See also DetailFields

Properties' Summary
MasterFields | is used for subforms and contains the names of columns of the parent form.
DetailFields | is used for subforms and contains the names of the columns of the subform which are related to the master fields of the parent form.
Cycle | returns the kind of tabulator controlling.
NavigationBarMode | determines how an navigation bar for this form should act.
AllowInserts | determines if insertions into the form's row set are allowed.
AllowUpdates | determines if modifications of the current record of the form are allowed.
AllowDeletes | determines if deletions of records of the form are allowed.

Properties' Details
MasterFields
sequence< string > MasterFields; Description is used for subforms and contains the names of columns of the parent form. These columns are typically the foreign key fields of the parent form. The values of theses columns are used to identify the data for the subform. Each time the parent form changes it's current row, the subform requeries it's data based on the values of the master fields.
DetailFields
sequence< string > DetailFields; Description is used for subforms and contains the names of the columns of the subform which are related to the master fields of the parent form. These columns represent typically a part of the primary key fields or their aliases of the detail form and are used as parameters in a database query to retrieve the details for an according master form.
Cycle
::com::sun::star::form::TabulatorCycle Cycle; Description returns the kind of tabulator controlling.
NavigationBarMode
::com::sun::star::form::NavigationBarMode NavigationBarMode; Description determines how an navigation bar for this form should act.
AllowInserts
boolean AllowInserts; Description determines if insertions into the form's row set are allowed. Note that this is a recommendation for user interface components displaying the form. Form implementations may decide to allow for insertions done via the API, even if the property is set to false , but the user interface should respect the property value.
AllowUpdates
boolean AllowUpdates; Description determines if modifications of the current record of the form are allowed. Note that this is a recommendation for user interface components displaying the form. Form implementations may decide to allow for updates done via the API, even if the property is set to false , but the user interface should respect the property value.
AllowDeletes
boolean AllowDeletes; Description determines if deletions of records of the form are allowed. Note that this is a recommendation for user interface components displaying the form. Form implementations may decide to allow for deletions done via the API, even if the property is set to false , but the user interface should respect the property value.

Top of Page

Copyright © 2003 Sun Microsystems, Inc.