
Announcements
I have developed the PowerApps template patched to a SharePoint list and there's a problem. I have seen others with similar problems but not really addressing mine.
I have two SharePoint Lists: BalanceLeave and LeavesAppliedByUser. The BalanceLeave holds all the types of leaves ( Annual Leave, Sick Leave, Casual Leave etc.. and the number of days). The LeavesAppliedByuser has all leaves application made by users. So basically I want to display the balance of the leave applied on PowerApps screen.
Below is my formula.
Sum(Filter(BalanceLeave,LeaveId=ThisItem.LeaveId),Total_Leave) - Sum(Filter(LeavesAppliedByUsers,LeaveId.Value=ThisItem.LeaveId && RequestedBy.Email=User().Email),TotalDays) & " Days".
At the moment, this formula doesn't deduct from the total leave days... The total leave balance never changes as i create leave requests.
Thanks for your help always
Kindly assist.