Edittable create and symbolic fields calculate - OI9 difference (OpenInsight 64-bit)
At 03 SEP 2020 07:13:08PM Barry Stevens wrote:
GST_TOTAL_AMOUNT and INVOICE_AMOUNT are symbolic fields that are related to the dict fields in the edittable.
Code in OI9 where it updates the GST_TOTAL_AMOUNT and INVOICE_AMOUNT get updated
DissectTable=Null$
DissectTable<1,1>=Qty
DissectTable<2,1>=CashBookAccCode
DissectTable<3,1>=xlate("CASH_BOOK_ACC_CODES",CashBookAccCode,"COST_CENTRE_ACCOUNT_DESCR","X")
DissectTable<6,1>=ItemPrice
DissectTable<7,1>=ItemPrice
DissectTable<8,1>=Gst
setproperty("@.DISSECTION_TABLE","INVALUE",DissectTable)
send_event(@Window:".GST_TOTAL_AMOUNT","CALCULATE")
send_event(@Window:".INVOICE_AMOUNT","CALCULATE")
Same Code in OI10, but the GST_TOTAL_AMOUNT and INVOICE_AMOUNT DON'T get updated
If I edit a value in the edittable, then they get updated.
So, what now is the correct method of creating an edittable and getting all associated symbolic fields to update.
At 03 SEP 2020 07:24PM Carl Pates wrote:
Barry,
After you have set the EditTable INVALUE - get the form's RECORD property and debug - do you see your new data from the EditTable in it at that point?
At 03 SEP 2020 08:16PM Barry Stevens wrote:
Barry,
After you have set the EditTable INVALUE - get the form's RECORD property and debug - do you see your new data from the EditTable in it at that point?
No I dont, but it is on the form.
At 03 SEP 2020 08:37PM Barry Stevens wrote:
Post removed by author
At 03 SEP 2020 08:52PM Barry Stevens wrote:
Barry,
After you have set the EditTable INVALUE - get the form's RECORD property and debug - do you see your new data from the EditTable in it at that point?
No I dont, but it is on the form.
If I do this it works. (But I assume that is not what is expected to have to do all the time)
setproperty("@.DISSECTION_TABLE","INVALUE",DissectTable)
atrecord = Get_Property(@window, 'ATRECORD')
Set_Property(@Window,"RECORD",AtRecord)
At 04 SEP 2020 04:44AM Carl Pates wrote:
Barry,
The flow of the original code is this:
INVALUE uses DEFPROP
DEFPROP updates a Window Common variable called SubRows@(0)
The CALCULATE event loads SubRows@(0) into @Record before executing the symbolic
The RECORD property returns the raw SubRows@(0)
So, if you don't see your data in RECORD then it's a bug and needs adding to the tracker so we don't lose sight of it.
Thanks,
At 04 SEP 2020 06:22PM Barry Stevens wrote:
Barry,
The flow of the original code is this:
INVALUE uses DEFPROP
DEFPROP updates a Window Common variable called SubRows@(0)
The CALCULATE event loads SubRows@(0) into @Record before executing the symbolic
The RECORD property returns the raw SubRows@(0)
So, if you don't see your data in RECORD then it's a bug and needs adding to the tracker so we don't lose sight of it.
Thanks,
At 16 JAN 2022 05:45PM Barry Stevens wrote:
Barry,
The flow of the original code is this:
INVALUE uses DEFPROP
DEFPROP updates a Window Common variable called SubRows@(0)
The CALCULATE event loads SubRows@(0) into @Record before executing the symbolic
The RECORD property returns the raw SubRows@(0)
So, if you don't see your data in RECORD then it's a bug and needs adding to the tracker so we don't lose sight of it.
Thanks,
I removed my 'get around' code and the issue is still there.
atrecord = Get_Property(@window, 'ATRECORD') Set_Property(@Window,"RECORD",AtRecord)