Hi,
I'm trying to build a simple Calendar app that uses a SharePoint list as the Data source.
I got the names to show on a side Gallery, but the Month-view Gallery shows Red circles for all dates, even though I have no events for these dates.
The collection capturing the input is as follows:
Collect(NaviaPTO, {StartDate: StartDatePopUp_1.SelectedDate, EndDate: EndDatePopUp_1.SelectedDate, Resource: ResourceName_1.Selected.DisplayName, OOOType: OOO_Type_1.SelectedText.Value})
My on select for the circle is:
CountRows(Filter(NaviaPTO,DateValue(Text('StartDate'))<=DateAdd(_firstDayInView,ThisItem.Value,Days),DateValue(Text('EndDate'))>=DateAdd(_firstDayInView,ThisItem.Value,Days)))>0&&!Subcircle1_2.Visible&&ResourceName_1.Visible
Any help would be greatly appreciated.
Solved! Go to Solution.
Hi @F_Quint ,
Regarding the screenshot that you mentioned, I think there is something wrong with your operation.
Just as I mentioned before, you should apply the following formula:
CountRows(
Filter(
NaviaPTO,
DateValue(Text(StartDate)) <= DateAdd(_firstDayInView,ThisItem.Value,Days),
DateValue(Text(EndDate)) >= DateAdd(_firstDayInView,ThisItem.Value,Days)
)
)>0 && !Subcircle1_2.Visible && Title3_2.Visible
into the Visible property of the Circle2_3 control rather than the OnSelect property as your screenshot mentioned. The OnSelect property would be fired when you click this Circle2_3 control. The Visible property of the Circle2_3 control would be used to control the visible of the red circle.
Please check if the solution in the following thread would help in your scenario:
Regards,
Hi @F_Quint ,
Do you want the red circle to be shown up for these dates which have Calendar Events?
Regarding the formula and operation that you mentioned, I think there is something wrong with it. Firstly, if you want to control the visible of the red circle in your MonthDayGallery1_2, you should apply the second formula into the Visible property of the Red circle icon (Circle2_2).
Please set the Visible property of the Red Circle (Circle2_2) to following:
CountRows(
Filter(
NaviaPTO,
DateValue(Text(StartDate)) = DateAdd(_firstDayInView,ThisItem.Value,Days)
)
)>0 && !Subcircle1_2.Visible && Title3_2.Visible
or
CountRows(
Filter(
NaviaPTO,
DateValue(Text(StartDate)) <= DateAdd(_firstDayInView,ThisItem.Value,Days),
DateValue(Text(EndDate)) >= DateAdd(_firstDayInView,ThisItem.Value,Days)
)
)>0 && !Subcircle1_2.Visible && Title3_2.Visible
Please try above solution, then check if the issue is solved.
Regards,
@v-xida-msft Thank you for that reply.
I tried what you suggested and I do show the red circle, but not for the dates in between. See side gallery dates.
Hi @F_Quint ,
Regarding the screenshot that you mentioned, I think there is something wrong with your operation.
Just as I mentioned before, you should apply the following formula:
CountRows(
Filter(
NaviaPTO,
DateValue(Text(StartDate)) <= DateAdd(_firstDayInView,ThisItem.Value,Days),
DateValue(Text(EndDate)) >= DateAdd(_firstDayInView,ThisItem.Value,Days)
)
)>0 && !Subcircle1_2.Visible && Title3_2.Visible
into the Visible property of the Circle2_3 control rather than the OnSelect property as your screenshot mentioned. The OnSelect property would be fired when you click this Circle2_3 control. The Visible property of the Circle2_3 control would be used to control the visible of the red circle.
Please check if the solution in the following thread would help in your scenario:
Regards,
@v-xida-msft you were right, I had it on the OnSelect.
sorry about that! And thank you for your help!
User | Count |
---|---|
177 | |
116 | |
85 | |
44 | |
41 |
User | Count |
---|---|
240 | |
153 | |
130 | |
77 | |
72 |