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 Apps
Answered

Calculation

(0) ShareShare
ReportReport
Posted on by 75

Hi all, 

 

I need your help in calculation because I'm getting confused in the middle of doing this calculation. The calculation goes like this: 

 

Leave date ( DataCardValue_LeaveDate ) and Return Date (DataCardValue_ReturnDate) is manually entered by user.

 

Balance ( DataCardValue_Balance ) will show how many days is available. For example 'Allocated' is 20 and 4 days has been used, Balance ( DataCardValue_Balance ) will show 16 days.

 

No of Days ( DataCardValue_NoOfDays ) is the same as Used ( DataCardValue_Used ).  It will show how many days is used. For example 'Allocated' is 20 and 4 days has been used, it will show 4 days on the data card value.

 

When user take one day leave (DataCardValue_LeaveDate) and return (DataCardValue_ReturnDate) on the same day, it should calculate as 0.5 days. How do I do this.

 

Also, Saturday and Sunday will be off day.

 

Many thanks for everyone help!!
@WarrenBelz @v-bofeng-msft @eka24 @v-qiaqi-msft @RandyHayes @Pstork1 @Rebetcha 

Image.PNG
Categories:
I have the same question (0)
  • Verified answer
    Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @HF306 

    Datediff(Datepicker1.SelectedDate,Datepicker2.SelectedDate) would be Default for dates used.  Balance would be allocated - used.

  • HF306 Profile Picture
    75 on at

    Appreciate the help @Drrickryp !! ^.^

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 541

#2
WarrenBelz Profile Picture

WarrenBelz 434 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 289

Last 30 days Overall leaderboard