Hello guys. Im trying to get the date that was 3 days ago, for example, today is 16th, I need 13th, but dont know what to add to the command that I have now DateTime.Now.ToString("yyyy.MM.dd")
Does anyone have any ideas? Thanks!
Try this expression
DateTime.Now.AddDays(-3).ToString("yyyy.MM.dd")
Regards
Gokul
1 Like
Hello @Povilas_Jonikas ., Try this
DateTime.Now.Adddays(-3).ToString(“yyyy.MM.dd”)
1 Like
For more detail refer this tutorial
Regards
Gokul
1 Like
Thanks guys, it works!
1 Like
This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.