Subject Re: [IBO] New to IBObjects and Interbase
Author Lucas Franzen

ray@... schrieb:
> I am new to Interbase and IBObjects and have a few basic questions.
> I am trying to setup my first form to access a table to edit data in
> a single record of the table. I have set up an TIB_Connection,
> TIB_Transaction, TIB_Query and TIB_DataSource and TIB_Edit's. I
> have set the properties to the TIB_Connection and TIB_Transaction to
> connect to my database and can open them. I am not sure where to go
> from here with the TIB_Query and TIB_DataSource and TIB_Edit's. How
> do I set the DataField property? I don't understand how to set the
> query to allow me to edit the fields in the table.

Prepare the Query (just change the Prepared-property to TRUE in the
ObjectInspector). Then you can connect your TIB_Edit to the DataSource
(which is connected to the Query) and then you're able to select the
DataField for the IB_Edit in the DataField property (the drop down list
will be filled with all the fields from the Query then).

How to edit Data:
To edit a record the Query has got to have the REquestLive property set
to true. Either do it in the ObjectInspector OR add "FOR UPDATE" to the
SQL of the Query; this will set the request live to true, too (Example:

To change in the EditState you could use the appropriate TIB_Bars (like
TIB_UpdateBar etc) or add the logic on your own (like calling Query.EDIT
/ Query.Insert / Query.POST (write data), Query.Cancel (Cancel
Insert/Edit) in your own procedures).

The query might even start the Edit on it's own, as soon as you're
entering something int he IB_Edits depending on several properties of
several involved controls (like: TIB_Qurey.PreventEditing /
TIB_DataSource.AutoEdit etc...))

> Getting Started With IBObjects help file but I seem to have missed a
> few basis steps. Is there any other help or examples I can refer
> to? I have tired to run the demos included with IBObjects but I do
> not have the database the which examples refer. Where can I find
> this database? Also does anyone have any recommendations for books
> on client/server development with Delphi?

The databases of the samples are
- either the databases that are delivered with Delphi (Enterprise, I'm
not sure about Professional) - if you haven't installed Delphi in the
"standard"-path you might have to correct the path
- they are created "on the fly", when the app starts.