cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Returning information from a specific entry in SharePoint

Hello,

 

I am trying to create a label that is visible only if Today() falls within a start and end date stored in a SharePoint List entry. I cannot figure out how to do get the specific index instead of the whole column when typing the formula.

 

In this case I want to write an if statement that first looks for the user's name in the title column of the SharePoint and then if that is located look at the dates for that entry to see if today falls between them. How would I do this?

 

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
K-A-R-L
Solution Specialist
Solution Specialist

Hi @Anonymous ,


Have you tried @Jeff_Thorpe  solution yet?

Try using and edit the codes below.

On your Label set the Visibilty Property to:

 

If(CountRows(
Filter(MyCalendarEvents,
Name.Text = "John Doe" //Name.Text is the name of the field on PA
&& Week_x0020_Start_x0020_Date >= Today() - Weekday(_dateSelected, StartOfWeek.MondayZero) //This will exclude weekends - Week_x0020_Start_x0020_Date  is my StartDate on SP List
&& Week_x0020_End_x0020_Date <= Today() +5 - Weekday(Today(), StartOfWeek.MondayZero) )) >= 1, //This will exclude weekends Week_x0020_End_x0020_Date  is my EndtDate on SP List
true,false)

----------------------------------------------------------------------------
Thanks,
K-A-R-L


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

2 REPLIES 2
Jeff_Thorpe
Super User
Super User

You could use the Lookup() to see if the record exists.

 

LookUp function in PowerApps



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
K-A-R-L
Solution Specialist
Solution Specialist

Hi @Anonymous ,


Have you tried @Jeff_Thorpe  solution yet?

Try using and edit the codes below.

On your Label set the Visibilty Property to:

 

If(CountRows(
Filter(MyCalendarEvents,
Name.Text = "John Doe" //Name.Text is the name of the field on PA
&& Week_x0020_Start_x0020_Date >= Today() - Weekday(_dateSelected, StartOfWeek.MondayZero) //This will exclude weekends - Week_x0020_Start_x0020_Date  is my StartDate on SP List
&& Week_x0020_End_x0020_Date <= Today() +5 - Weekday(Today(), StartOfWeek.MondayZero) )) >= 1, //This will exclude weekends Week_x0020_End_x0020_Date  is my EndtDate on SP List
true,false)

----------------------------------------------------------------------------
Thanks,
K-A-R-L


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

Helpful resources

Announcements
User Groups Public Preview

Join us for our User Group Public Preview!

Power Apps User Groups are coming! Make sure you’re among the first to know when user groups go live for public preview.

Power Apps Community Call

Monthly Power Apps Community Call

Did you miss the call?? Check out the Power Apps Community Call here!

Power Platform ISV STudio

Power Platform ISV Studio

ISV Studio is the go-to Power Platform destination for ISV’s to monitor & manage applications post-AppSource publish.

Top Solution Authors
Top Kudoed Authors
Users online (31,564)