none
Customized date value parameter

    Question

  • Hi guys! how can i achieve to add expression to read 1st of January of previous year?

    i want to have only previous year only but need to be default to January 1st.

    =DATEVALUE("January 1, DATEADD("Y",-1,YEAR(TODAY))"  this won't work.. 

    thanks in advance! 


    • Edited by jefnavarro Wednesday, September 11, 2013 5:08 AM
    Wednesday, September 11, 2013 5:07 AM

Answers

  • try this:

    =DATEVALUE((YEAR(TODAY()) - 1).ToString() + "-01-01")


    Regards Harsh

    • Marked as answer by jefnavarro Wednesday, September 11, 2013 5:31 AM
    Wednesday, September 11, 2013 5:27 AM

All replies

  • try this:

    =DATEVALUE((YEAR(TODAY()) - 1).ToString() + "-01-01")


    Regards Harsh

    • Marked as answer by jefnavarro Wednesday, September 11, 2013 5:31 AM
    Wednesday, September 11, 2013 5:27 AM
  • that's quick! :) Thank you very much!
    Wednesday, September 11, 2013 5:31 AM
  • If you want to use your expression you can use like this 

    =DateValue("January 1,"+  (Year(Now())-1).ToString)

    Amish shah

    http://blog.sqltechie.com

    Wednesday, September 11, 2013 6:13 AM