Hello power Apps Team ^^
I hope someone can help me because I am struggling for a few days...
- To start, I created an event Sharepoint list composed of these fields:
| Event Name | Min number of Participants | Max Number of Participants |
| Text field | Number | Number |
- Then, I created another SharePoint list called Inscription with these fields:
| Event Name | Attendee | Min Participant | Max Participant | Status | Recurrence |
| Lookup from event List | text field | Lookup from event List | Lookup from the event list | Confirmed or Cancelled | calculated en powerapps |
- I am looking to display a popup msg when the number of lines in the inscription list ( status Confirmed)=max number of participants. I created the recurrence field with the following calculation
CountRows(Filter('Enrollment test 2','Event Name'.Value=DataCardValue2.Selected.Value && Status.Value="Confirmed"))
so if I have 5 lines confirmed in the participant list, recurence=5
For the popup msg, it should be displayed if the number of recurrence= max participant for the selected event name.
The question is: how can I get the max number of participants based on previously entered lines related to the same event name? For example, I have 3 existing lines for event line 'Site' ( status Confirmed) with max participants 3. I start creating a new line in Sharepoint with the same event name 'Site'. When I select it and status 'Confirmed', a pop-up msg should appear mentioning that I reached the max number of participants ( lines insharepoints=max participants).
Thanks for any help,
Sabrina