Dear all,
I struggling with the following situation :
Instructions
| Reference | Name |
| C-VIK-015 | Instruction Card 1 |
| C-VIK-016 | Instruction Card 2 |
| C-VIK-017 | Instruction Card 3 |
Performed Instructions with the following columns
| Reference | Instruction Reference | |
| | Lookup towards Instruction table | |
I have a gallery based on a collection where all performed instruction are listed.
What i want to do is patch this to the table Performed Instruction.
I've written the following code to achieve this
ForAll(
GalInstrInsp.AllItems,
Patch(
[@'Inspection Instructions'],
Defaults([@'Inspection Instructions']),
{
Reference: GUID(),
'Instruction Reference': LookUp(colInstructions,Reference in GalInstrInsp.AllItems.Reference)
}
)
);
In the collection of the gallery following records are shown (reference is not displayed in the gallery)
Instruction Card 1
Instruction Card 3
When i patch, the result in the performed inspection table is two times C-VIK-015. It seems that my code is not taking the next record.
Does someone has a solution for this ?
Kind regards
Steve