Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Bazza
 
Posts: n/a
Default only show workdays in a cell

If I am adding records in to a spreadsheet, I want it to count the number of
days that record has been on the spreadsheet for.

For example I am currently using the code =TODAY() but this also includes
weekends.

So when if =TODAY() is in A1

The date I am entering the record is in A2

=sum(A1-A2)

This works well but once it comes to Thursday and Friday it starts to count
the weekends as well giving an in accurate reading.

Please can someone help me

Thanks

  #2   Report Post  
Peo Sjoblom
 
Posts: n/a
Default

Look in help for NETWORKDAYS, also no need to sum, =A2-A1 will do
or if you want to save space

=A2-TODAY()

However using networkdays

=NETWORKDAYS(TODAY(),A2,Holidays)

where Holidays in this example is a named range that holds public holidays
but can also be a regular range like H2:H12 for instance

NETWORKDAYS is part of the Analysis ToolPak add-in that comes with excel,
if not installed at first time have the office/escel cd handy, check it
under toolsadd-ins and follow the instructions


Regards,

Peo Sjoblom


"Bazza" wrote:

If I am adding records in to a spreadsheet, I want it to count the number of
days that record has been on the spreadsheet for.

For example I am currently using the code =TODAY() but this also includes
weekends.

So when if =TODAY() is in A1

The date I am entering the record is in A2

=sum(A1-A2)

This works well but once it comes to Thursday and Friday it starts to count
the weekends as well giving an in accurate reading.

Please can someone help me

Thanks

  #3   Report Post  
 
Posts: n/a
Default

hi
you might try the =networkday function
=NETWORKDAYS(TODAY(),A1)
you can sub a1 for today() and change the other cell to a2.
you can also skip holidays too
=NETWORKDAYS(TODAY(),A1, holiday range)
where holiday range is a range that contains all of your
holidays.

-----Original Message-----
If I am adding records in to a spreadsheet, I want it to

count the number of
days that record has been on the spreadsheet for.

For example I am currently using the code =TODAY() but

this also includes
weekends.

So when if =TODAY() is in A1

The date I am entering the record is in A2

=sum(A1-A2)

This works well but once it comes to Thursday and Friday

it starts to count
the weekends as well giving an in accurate reading.

Please can someone help me

Thanks

.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
show macro security setting in a cell Mark Excel Worksheet Functions 3 March 21st 05 07:53 AM
Show a time from one calculated cell as a decimal in another cell. KathyS Excel Worksheet Functions 1 January 20th 05 01:00 AM
GET.CELL Biff Excel Worksheet Functions 2 November 24th 04 07:16 PM
Cell doesn't show formula result - it shows formula (CTRL + ' doe. o0o0o0o Excel Worksheet Functions 6 November 19th 04 03:13 PM
cell reference show cell name (ie. D45) and not cell value ria Excel Worksheet Functions 4 November 6th 04 04:38 AM


All times are GMT +1. The time now is 05:22 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"