In the method modifiedField my code modifies fields from the table
(lines of the document) and a fields in another table (document
header). (Tables are associated with foreign key)
How to call a refresh on the form, from the code that is implemented
on the table? Few diffrent forms may use these tables, so I wan't to
refresh them all.
Sorry for bad english.
Regards
Peter
if (table.isFormDataSource())
{
table.dataSource().refresh();
}
But you shouldn't save a record in the modifiedField(). Use this method only
for an initialization of fields. Simply set values to the "this" buffer (e.g.
this.Field1 = '') and no refresh is needed.
Also, you should update other tables during a record saving - e.g. in the
insert() method.
--
Best regards,
Martin Drab (Czech Blog: http://dax-cz.blogspot.com)
"arnam" wrote:
> .
>
On the first table (lines of document), from which modifiedField() is
executed I use "this" buffer, but related table (header of document)
is modified using 'select forUpdate' clause. So first table has
relation to dataSource, but second table doesn't (dataSource() is
nil).
> Use this method only
> for an initialization of fields. Simply set values to the "this" buffer (e.g.
> this.Field1 = '') and no refresh is needed.
> Also, you should update other tables during a record saving - e.g. in the
> insert() method.
Yes, but I need to display updated data on the form, on the controls
connected with the header table, immediately after update of lines
table.
Regards