Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default =TODAY() function to fix the date


I want to fix the date in a cell with a formula whenever other cell is
populated.
e.g when cell B1 is populated, cell A1 should show the date of that day
and that should not change later on.
I have seen some posts with the same question but with no answer.
any guru on this..??


--
starguy
------------------------------------------------------------------------
starguy's Profile: http://www.excelforum.com/member.php...o&userid=32434
View this thread: http://www.excelforum.com/showthread...hreadid=561042

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,316
Default =TODAY() function to fix the date

In cell A1 place this formula:

=IF(ISBLANK(E1),"",DATE(YEAR(TODAY()),MONTH(TODAY( )),DAY(TODAY())))

If the result displays as an integer, format the cell using the date format
of choice.
--
Kevin Backmann


"starguy" wrote:


I want to fix the date in a cell with a formula whenever other cell is
populated.
e.g when cell B1 is populated, cell A1 should show the date of that day
and that should not change later on.
I have seen some posts with the same question but with no answer.
any guru on this..??


--
starguy
------------------------------------------------------------------------
starguy's Profile: http://www.excelforum.com/member.php...o&userid=32434
View this thread: http://www.excelforum.com/showthread...hreadid=561042


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,441
Default =TODAY() function to fix the date

Starguy,

You need to use a worksheet change event to do that: for example, for
any cell in column B, the date when the entry is made or changed is stored in column A
using this code:

Private Sub Worksheet_Change(ByVal Target As Range)
Dim myCell As Range
If Intersect(Target, Range("B:B")) Is Nothing Then Exit Sub
Application.EnableEvents = False
For Each myCell In Intersect(Target, Range("B:B"))
Cells(myCell.Row, 1).Value = Now
Cells(myCell.Row, 1).NumberFormat = "mm/dd/yy hh:mm:ss"
Next myCell
Application.EnableEvents = True
End Sub

Copy this code, right-click on the worksheet tab, select "View Code" and
paste the code in the window that appears.

HTH,
Bernie
MS Excel MVP


"starguy" wrote in message
...

I want to fix the date in a cell with a formula whenever other cell is
populated.
e.g when cell B1 is populated, cell A1 should show the date of that day
and that should not change later on.
I have seen some posts with the same question but with no answer.
any guru on this..??


--
starguy
------------------------------------------------------------------------
starguy's Profile: http://www.excelforum.com/member.php...o&userid=32434
View this thread: http://www.excelforum.com/showthread...hreadid=561042



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 26
Default =TODAY() function to fix the date

Kevin, will not the date change in your case??

Kevin B skrev:

In cell A1 place this formula:

=IF(ISBLANK(E1),"",DATE(YEAR(TODAY()),MONTH(TODAY( )),DAY(TODAY())))

If the result displays as an integer, format the cell using the date format
of choice.
--
Kevin Backmann


"starguy" wrote:


I want to fix the date in a cell with a formula whenever other cell is
populated.
e.g when cell B1 is populated, cell A1 should show the date of that day
and that should not change later on.
I have seen some posts with the same question but with no answer.
any guru on this..??


--
starguy
------------------------------------------------------------------------
starguy's Profile: http://www.excelforum.com/member.php...o&userid=32434
View this thread: http://www.excelforum.com/showthread...hreadid=561042


  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default =TODAY() function to fix the date


date is changed, any other to solve this problem without VBA (if
possible)


=IF(ISBLANK(E1),"",DATE(YEAR(TODAY()),MONTH(TODAY ()),DAY(TODAY())))

If the result displays as an integer, format the cell using the date

format
of choice.
--
Kevin Backmann



--
starguy
------------------------------------------------------------------------
starguy's Profile: http://www.excelforum.com/member.php...o&userid=32434
View this thread: http://www.excelforum.com/showthread...hreadid=561042

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
Date function in Excel that updates only when a doc is changed? torino0020 Excel Worksheet Functions 1 January 5th 06 03:00 AM
Date Function Khangura Excel Discussion (Misc queries) 1 December 21st 05 09:33 AM
date format and the RIGHT function Rich Hayes Excel Worksheet Functions 2 December 19th 05 12:29 PM
date format and the RIGHT function Rich Hayes Excel Worksheet Functions 0 December 19th 05 11:06 AM
How do I use the concatenate function to add a date into a sentenc Ken Janowitz Excel Worksheet Functions 6 December 13th 05 10:41 PM


All times are GMT +1. The time now is 08:21 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"