cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
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
Level 10

Re: Returning information from a specific entry in SharePoint

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
Super User
Super User

Re: Returning information from a specific entry in SharePoint

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
Level 10

Re: Returning information from a specific entry in SharePoint

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
Better Together’ Contest Finalists Announced!

'Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Join THE global Microsoft Power Platform event series

Attend for two days of expert-led learning and innovation on topics like AI and Analytics, powered by Dynamic Communities

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

thirdimage

Microsoft Business Applications Virtual Launch

Join us for the Microsoft Business Applications Virtual Launch Event on Thursday, April 2, 2020, at 8:00 AM PST.

thirdimage

Community Summit North America

Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (9,892)