Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Formula for week ending

Hi

I am putting together a time sheet to record working times from week to
week, I have a cell that contains the week ending date using the following
formula:

=TODAY()-WEEKDAY(TODAY(),2)+7

I need to make this cell only update if the file is saved, basically so that
if I open an old timesheet from say last week it wont change the week ending
date to this weeks.

Does that make sense?? lol

Hope someone can help
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 248
Default Formula for week ending

The only way to do that is to convert the formula to a value before saving...
i.e Copy and then Paste Special | Values

You can record a macro while doing that and then run that macro whenever you
want...
-------------------------------------
Pl. click ''''Yes'''' if this was helpful...



"Nelix" wrote:

Hi

I am putting together a time sheet to record working times from week to
week, I have a cell that contains the week ending date using the following
formula:

=TODAY()-WEEKDAY(TODAY(),2)+7

I need to make this cell only update if the file is saved, basically so that
if I open an old timesheet from say last week it wont change the week ending
date to this weeks.

Does that make sense?? lol

Hope someone can help

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 806
Default Formula for week ending

Hello,

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Range("A1") = Application.WorksheetFunction.Floor(CLng(Date) + 5,
7) + 1
End Sub


Regards,
Bernd
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
Convert regular Date to Week Ending or Week Beginning Dates Sam H Excel Discussion (Misc queries) 5 April 3rd 23 04:39 PM
week ending peter Excel Worksheet Functions 4 April 3rd 08 03:31 AM
Week Ending formula cindi Excel Discussion (Misc queries) 2 July 11th 07 09:03 PM
AVG row of data by Week ending JmyCrikitt Excel Discussion (Misc queries) 4 January 25th 07 06:28 AM
Week ending [email protected] Excel Worksheet Functions 3 November 1st 05 04:52 PM


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

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

About Us

"It's about Microsoft Excel"