
Hi everyone, I hope you can oriented me to do this
I'm working with a couple of collections, the first, I'm using it as an auxiliary to do a For loop condition for the other collection. This is the collection
Collect(colMonths; [1;2;3;4;5;6;7;8;9;10;11;12;13]);;
This is the second collection
Collect(
colTableMonth;
{
'Contract Day': "";
Month: "";
Capital: "";
Rend: "";
Ret: "";
Pay: ""
}
);;
I'm populating the columns with some formulas and I need to populate the column Pay with the result of add the columns Rend and Ret. Is there anyway to do it with ForAll? This is part of my code
ForAll(colMonths;
Patch(colTableMonth;Defaults(colTableMonth);
{
'Contract Day': Here I have a formula;
Month: ThisRecord.Value;
Capital: VarCap1;
Rend: A formula that fills this column depending some conditions;
Ret: A formula that fills this column depending some conditions;
Pay: Here, I need this: Rend - Ret
}
));;
I tried to update the column after my code is executed with the code below, but is also not working
Patch(colTableMonth; Filter(colTableMonth;Pay=0);{'Pago Efectivo':"3"});;
I think the explanations is clear (jejeje) Can you help me? Thanks in advance