Subject Re: How to get data into a table
Author Eric Handbury
--- In IBObjects@y..., "Florian Hector" <FHector@w...> wrote:
>
> How do I get data which is not entered through a data sensitive
control into
> a table (IB_Query). As long as there were persistent fields I
could do
>
> I put this in the AfterInsert event of IB_Query:
> "qryBooks.ParamByName('BuyDate').asString :=
> DateToStr(frmBooklist.dtpBuyDatum.Date)", all I ever get is a
message saying
> "Fieldname: BuyDate cannot be found".
>
> I managed to get it to work using the IB_Date but not as
comfortable as when
> using DTP so I'd be grateful to know how it can be done.

The syntax is:
qryBooks.FieldByName('BuyDate').asString = ...

I always use the OnNewRecord to manually populate fields.

HTH, Eric.