cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Blipstar
Frequent Visitor

Datepicker + Value from ComboBox to provide a new date.

Hello all,

 

Working on a small solution for my team but i've hit a wall with figuring out how to calculate a date, and wondering if somone could help.

 

Within my PowerApp I have a date picker filed labelled "Date Access Required", the next field is a "Access Length" which is a combo box with the values 1,2,6,8,12  all which represent months.   I'm trying to figure how I can create a "Date to remove access" by calculating 'Date access required'+ 'Access Length' selected value from the combo box and give me a formatted date. I've managed to do this using the calculated column in SharePoint but unfortunately when using Power Automate OData can't filter Calculated columns, so I decided to apply this at the app level so it will update SharePoint as a simple string so I can then use the Odata filter.

 

This is the calculation that SharePoint used 

 

 

=DATE(YEAR([Date Access Required]),MONTH([Date Access Required])+[Access Length(M)],DAY([Date Access Required]))

 

 

Many thanks in advanced!

 

1 ACCEPTED SOLUTION

Accepted Solutions
StalinPonnusamy
Super User
Super User

Hi @Blipstar 

 

 

 

DateAdd(DatePicker1.SelectedDate,Value(Dropdown2.Selected.Value),Months)

 

 

 

StalinPonnusamy_0-1634574176851.png

 

DatePicker1 - Date Access Required

DropDown2 - Access Length

 


Thanks,
Stalin - Learn To Illuminate

View solution in original post

2 REPLIES 2
StalinPonnusamy
Super User
Super User

Hi @Blipstar 

 

 

 

DateAdd(DatePicker1.SelectedDate,Value(Dropdown2.Selected.Value),Months)

 

 

 

StalinPonnusamy_0-1634574176851.png

 

DatePicker1 - Date Access Required

DropDown2 - Access Length

 


Thanks,
Stalin - Learn To Illuminate

Blipstar
Frequent Visitor

Wow! thank you! was so close to actually working that out but so slightly wrong, now I'm reading your formula it makes perfect sense. Thank you!  

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Difinity Conference 2022

Difinity Conference 2022

Register today for two amazing days of learning, featuring intensive learning sessions across multiple tracks, led by engaging and dynamic experts.

European SharePoint Conference

European SharePoint Conference

The European SharePoint Conference returns live and in-person November 28-December 1 with 4 Microsoft Keynotes, 9 Tutorials, and 120 Sessions.

Power Apps Ideas

Changes to Ideas Coming

We are excited to announce a new way to share your ideas for Power Apps!

Top Solution Authors
Top Kudoed Authors
Users online (1,661)