Date minus 3 days

i need to get the current date minus 3 days in the format

29 June 2020

The below will give it to me but wont work if its on the first 3 days of the month.

DateTime.Now.AddDays(-3).ToString(“dd”) + " " + DateTime.Now.ToString(“MMMM”) + " " + DateTime.Now.ToString(“yyyy”)

You can just get the date in one single variable:

DateTime.Now.AddDays(-3).ToString(“dd MMMM yyyy”)

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.