Sharepoint - Column calculated value to get the current date time?

Unfortunately if you are trying to have this always show the current date and time, this won't work since Calculated Columns are not recalculated on viewing, but only on creation and modification. See this article: http://blog.pentalogic.net/2008/11/truth-about-using-today-in-calculated-columns/

However, if you are just trying to extract the time when calculated then you could switch your formula to: =TEXT([Modified],"mm-dd-yyyy hh:mm:ss")


you can also Use Now() instead of Today()

=TEXT(Now(),"mm-dd-yyyy hh:mm")

a sample for date diff

=IF(NOW()<=[End Date], 
DATEDIF(NOW(),[End Date],"d"), 
DATEDIF([End Date],NOW() ,"d") * -1)

Tags: