Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-09-2015, 06:20 PM
Azleenda Azleenda is offline Adding Formula Windows 7 64bit Adding Formula Office 2007
Novice
Adding Formula
 
Join Date: Nov 2015
Posts: 4
Azleenda is on a distinguished road
Default Adding Formula

Hi,

I have this formula which helps to count the no.of days, but i notice it includes the weekends & holidays.

How do i exclude the weekends & holidays to my current formula?

=IF(ISBLANK(AG123),TODAY()-AD123,(AG123-AD123))

Thanks in Advance
Reply With Quote
  #2  
Old 12-10-2015, 09:11 AM
Pecoflyer's Avatar
Pecoflyer Pecoflyer is offline Adding Formula Windows 7 64bit Adding Formula Office 2010 64bit
Expert
 
Join Date: Nov 2011
Location: Brussels Belgium
Posts: 2,920
Pecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond repute
Default

Have a look at the NETWORKDAYS function
__________________
Using O365 v2503 - Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post
Reply With Quote
  #3  
Old 12-10-2015, 07:24 PM
Azleenda Azleenda is offline Adding Formula Windows 7 64bit Adding Formula Office 2007
Novice
Adding Formula
 
Join Date: Nov 2015
Posts: 4
Azleenda is on a distinguished road
Default Adding Formula

Hi,

Still don't get it. Here i attached the spreadsheet.

If you see cell C6, its counting 7 inclusive of weekends. How can i exclude the weekends without messing up the current formula?

Please help
Attached Files
File Type: xls Testing.xls (39.0 KB, 13 views)
Reply With Quote
  #4  
Old 12-17-2015, 04:27 AM
SumitBansal SumitBansal is offline Adding Formula Windows 10 Adding Formula Office 2013
Novice
 
Join Date: Dec 2015
Location: India
Posts: 6
SumitBansal is on a distinguished road
Default

Try this:

=IF(ISBLANK(E6),TODAY()-B6,NETWORKDAYS(B6,E6,$F$6:$F$18))
Reply With Quote
  #5  
Old 12-11-2015, 12:53 AM
Pecoflyer's Avatar
Pecoflyer Pecoflyer is offline Adding Formula Windows 7 64bit Adding Formula Office 2010 64bit
Expert
 
Join Date: Nov 2011
Location: Brussels Belgium
Posts: 2,920
Pecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond reputePecoflyer has a reputation beyond repute
Default

Your formula =IF(ISBLANK(E6);TODAY()-B6;(E6-B6)) becomes

Code:
=IF(ISBLANK(E6);NETWORKDAYS(B6,TODAY()),NETWORKDAYS(B6,E6))
You have the option to add a range to the function, range containing the holidays.

Check the function's syntax to see how it works
__________________
Using O365 v2503 - Did you know you can thank someone who helped you? Click on the tiny scale in the right upper hand corner of your helper's post
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Need help with dragging a formula and changing a reference column as I drag the formula. LupeB Excel 1 10-22-2015 03:02 PM
Adding Formula Adding Months TimmiAndrew Excel 2 09-16-2015 10:21 AM
Adding Formula adding a red box jolinchew Word 8 07-12-2013 11:46 PM
Adding Formula Adding Image into a excel cell and adding a hyperlink to the image saravananiyyanar Excel 3 05-04-2011 08:31 AM
Adding Formula Adding PDF sussertown Office 2 06-13-2009 01:10 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 02:02 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft