web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Date functions highlig...
Power Apps
Answered

Date functions highlighs red

(1) ShareShare
ReportReport
Posted on by 65

I have 2 apps and the same formula seems to be working for my old app but not the new one.

Please can some one help with the right functions? In the app i the date is underlines red. I need help with the below functions

 

Sort(
Filter(
'Housing Packet',
(StartsWith(Title, TextInput2.Text)
|| StartsWith(LastName, TextInput2.Text)
|| StartsWith(CityFHEPS, TextInput2.Text)
|| StartsWith(EHV, TextInput2.Text)
|| StartsWith("2010E", TextInput2.Text))

&& (IsBlank(DropDown11.Selected.Value)
|| CityFHEPS = DropDown11.Selected.Value)

&& DateValue(Date) >= DatePicker11.SelectedDate
&& DateValue(Date) <= DatePicker12.SelectedDate

&& (IsBlank(DropDown12.Selected.Value)
|| EHV = DropDown12.Selected.Value)

&& DateValue(Date) >= DatePicker11.SelectedDate
&& DateValue(Date) <= DatePicker12.SelectedDate

&& Status.Value = Dropdown55.Selected.Value
),
"ID",
SortOrder.Descending

)

 

Screen Shot 2023-06-26 at 6.56.50 AM.png

 

Screen Shot 2023-06-26 at 6.56.50 AM.png
Categories:
  • Verified answer
    Shaheer Ahmad Profile Picture
    2,194 Moderator on at

    In the formula you provided, the issue seems to be with the Date functions causing the dates to be highlighted in red. To resolve this, you can modify the formula as follows:

     

    Sort(
     Filter(
     'Housing Packet',
     (StartsWith(Title, TextInput2.Text)
     || StartsWith(LastName, TextInput2.Text)
     || StartsWith(CityFHEPS, TextInput2.Text)
     || StartsWith(EHV, TextInput2.Text)
     || StartsWith("2010E", TextInput2.Text))
     && (IsBlank(DropDown11.Selected.Value)
     || CityFHEPS = DropDown11.Selected.Value)
     && Date >= DatePicker11.SelectedDate
     && Date <= DatePicker12.SelectedDate
     && (IsBlank(DropDown12.Selected.Value)
     || EHV = DropDown12.Selected.Value)
     && Date >= DatePicker11.SelectedDate
     && Date <= DatePicker12.SelectedDate
     && Status.Value = Dropdown55.Selected.Value
     ),
     "ID",
     SortOrder.Descending
    )

    In the modified formula, I removed the unnecessary DateValue functions and updated the conditions involving the Date column. The Date column is now directly compared with the selected dates from DatePicker11 and DatePicker12.

    Make sure to replace "Date" with the actual column name from your 'Housing Packet' table that contains the date values.

    By making these changes, the red underline error should be resolved, and the formula should function correctly in your new app.

    Mark as solution if this solves your problem. Let me know if you need further assistance

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 393 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 328

#3
WarrenBelz Profile Picture

WarrenBelz 278 Most Valuable Professional

Last 30 days Overall leaderboard