I have an email form template with a repeating table with 3 columns (Comments, Email, Date):
QC_Group
- QC_Table
QC_Comments
QC_Email
QC_Date
QC_SendTo
Let's say the data is as follows:
Row1 - Comment1 - Email1 - Date1
Row2 - Comment2 - Email2 - Date2
Row3 - Comment3 - Email3 - Date3
QC_SendTo should contain the email address of the previous row from the last/bottom row.
For example:
If I insert Row3, I want QC_Sendto = Email2
If I insert a new Row4, I want QC_Sendto = Email3
How do I do this?
I tried using QC_SendTo[last()] -- but it does not change the value from Email1. I'm guessing last() does not refer to the last row. I tried preceding-sibling but Im still confused over it so i can't even explain how i tried it.
Any help or guidance is greatly appreaciated. Thank you.