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

Count date and next data field

Sir,

I have a list of employees In & Out time record 

Time                                 In/Out

3/7/2020 2:03 PM               IN

3/7/2020 2:05 PM               OUT

 

I need a Label which should display How many employees are IN at that point of time or date. I used below formula

 

CountIf(Filter(Table2,Text(DateValue(Date,"en-US"),DateTimeFormat.ShortDate)>Text(Today(),DateTimeFormat.ShortDate)),'IN/OUT'="IN")

 

Pls help me out 

1 ACCEPTED SOLUTION

Accepted Solutions
Microsoft
Microsoft

Hi@Nandha,

Could you please share more about your scenario, do you want to count all the "In" items at that Date, like 3/8/2020?

I have made a test on my side, please take a try as below.

I have a SharePoint list as my data source. I have a gallery populated with Table2 containing a similar data structure as yours.

Add a Label and set the Text property as below

 

CountRows(Filter(BrowseGallery1.AllItems,Day(DateTimeValue(Title2.Text))= Day(Date(2020,3,8)),Subtitle2.Text="In" ))

070602.png

 

Best Regards,

Qi

View solution in original post

4 REPLIES 4
Resolver IV
Resolver IV

Hi @Nandha !

 

If you just want to know how many employees that currently are "IN", you only need to take the Employees in - Employees out. Like this:

CountRows(Filter(Table2,In/Out = "In")) - CountRows(Filter(Table2,In/Out = "Out"))

 

However, if you should be able to see how many are in for a certain time and date, just add that to the filter.

 

BR

Pontus 

Date time column will have a month data

I need to count IN for the current day only

Your formula will give total IN of the the month

Microsoft
Microsoft

Hi@Nandha,

Could you please share more about your scenario, do you want to count all the "In" items at that Date, like 3/8/2020?

I have made a test on my side, please take a try as below.

I have a SharePoint list as my data source. I have a gallery populated with Table2 containing a similar data structure as yours.

Add a Label and set the Text property as below

 

CountRows(Filter(BrowseGallery1.AllItems,Day(DateTimeValue(Title2.Text))= Day(Date(2020,3,8)),Subtitle2.Text="In" ))

070602.png

 

Best Regards,

Qi

View solution in original post

Microsoft
Microsoft

Hi@Nandha,

Have you solved your issue? 

if it solved your issue consider Accept it as the solution to help the others find it more.

Best Regards,

Qi

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Users online (7,105)