Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jim
 
Posts: n/a
Default Calculate the closest day

Hello,

I am creating a time card. I would like a formula that will calculate
(show) Fridays date closest to the date when the spreadsheet is opened. For
example If I opened the sheet today the formula would populate yesterdays
date. If I opened the sheet on Tuesday, the sheet formula will populate next
Fridays date, etc€¦

Thanks

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
CLR
 
Posts: n/a
Default Calculate the closest day

Assuming the date of the sheet opening is in A1.....

=TEXT(A1+LOOKUP(WEEKDAY(A1),{1,2,3,4,5,6,7},{-2,-3,3,2,1,0,-1}),"mm/dd/yyyy
dddd")

Vaya con Dios,
Chuck, CABGx3



"Jim" wrote in message
...
Hello,

I am creating a time card. I would like a formula that will calculate
(show) Fridays date closest to the date when the spreadsheet is opened.

For
example If I opened the sheet today the formula would populate yesterdays
date. If I opened the sheet on Tuesday, the sheet formula will populate

next
Fridays date, etc.

Thanks



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
daddylonglegs
 
Posts: n/a
Default Calculate the closest day


Try this formula

=TODAY()+CHOOSE(WEEKDAY(TODAY()),-2,-3,3,2,1,0,-1)


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=501413

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Jim
 
Posts: n/a
Default Calculate the closest day

perfect

"CLR" wrote:

Assuming the date of the sheet opening is in A1.....

=TEXT(A1+LOOKUP(WEEKDAY(A1),{1,2,3,4,5,6,7},{-2,-3,3,2,1,0,-1}),"mm/dd/yyyy
dddd")

Vaya con Dios,
Chuck, CABGx3



"Jim" wrote in message
...
Hello,

I am creating a time card. I would like a formula that will calculate
(show) Fridays date closest to the date when the spreadsheet is opened.

For
example If I opened the sheet today the formula would populate yesterdays
date. If I opened the sheet on Tuesday, the sheet formula will populate

next
Fridays date, etc.

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
how to calculate a cube root kiran Rajguru New Users to Excel 2 November 16th 05 10:50 AM
Shading or Choosing closest lacosta Excel Worksheet Functions 5 October 19th 05 06:57 PM
Spreadsheet Won't Calculate Scott Excel Discussion (Misc queries) 0 September 29th 05 05:37 PM
Match Closest Results from Data Array TheRobsterUK Excel Discussion (Misc queries) 2 September 29th 05 01:48 PM
How do you calculate the nth root of a number in Excel 2003? William Excel Worksheet Functions 2 November 17th 04 04:19 PM


All times are GMT +1. The time now is 11:29 AM.

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"