Using a report, I have a dataItem based on Ax Slave table. On After Get Record trigger I want to check if there is already inserted the combination between customer, caseID and InsuranceCompanyName and if it's then I just increment one field. I'm using the same table Ax Slave but is a temp table
The problem is that I cannot insert more than one record in the temp table.
I have the following code:
AX Slave - OnAfterGetRecord()
IF TempAXSlave.FINDFIRST THEN BEGIN
TempAXSlave.MaxResults += 1;
END ELSE BEGIN
//SlaveID += 1;
TempAXSlave.SlaveID += 1;
TempAXSlave.AccountNumber := "AX Slave".AccountNumber;
TempAXSlave.CaseID := "AX Slave".CaseID;
TempAXSlave.InsuranceCompanyName := "AX Slave".InsuranceCompanyName;
on the AX Slave - OnPostDataItem() I want to generate an excel file based on the temp table. But when I do TempAXSlave.FINDSET I see there is only one record in that table.
Can you please help me with this problem ?