Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 4 of 4 total
Thread Create table component and fields dynamically but can't get Mastersource working
Sun, Feb 5 2017 12:38 PMPermanent Link

Mike

The created fields are standalone available in a grid but linking two tables seems not to be possible.

The following message appears, Cannot access index field '__RowID'

Hope anyone has suggestions what could cause this.
Sun, Feb 5 2017 1:51 PMPermanent Link

Fernando Dias

Team Elevate Team Elevate

Mike,

The database tables, do they have a Primary Key ?
Also, what values are you assigning to TEDBTable.MasterFields and TEDBTable.IndexFieldNames after creating the components?
Please check that out...

--
Fernando Dias
[Team Elevate]
Sun, Feb 5 2017 2:13 PMPermanent Link

Mike

Hi Fernando,

Table1 is filled with orders and table2 has rows with order lines.

Table1
=====
OrderID (is primary key)
CustomerID
etc.

Table2
=====
OrderID
LineNumber

Because I can't create a primary key for for table table 2 I have created an normal index on fieldname OrderID.

The following code is used for the master source link.

 Table2.IndexName := '';
 Table2.MasterSource := DataSource1;
 Table2.MasterFields := 'OrderID';
Sun, Feb 5 2017 2:55 PMPermanent Link

Mike

Hi Fernando,

Writing it down helped Smile

An incorrect indexname was used.

Thanks for your help!
Image