Hi Chelsey,
The code you posted above is creating a variable, called "dayBeforeYesterday", that is calculated as the current day of the month minus two; for example, the current date is March 24, so the "getDate" method will return the integer 24, and the variable will hold the number 22, which isn't a valid date for use in AWQL.
You need to create a new date that is two days in the past, then format it as a valid text string using code similar to the "formatDate" function from my last post. To create the date, you can pass a UNIX timestamp to the constructor, in a similar way to the "addDays" function I used, or you can use the "setDate" method:
var dayBeforeYesterday = new Date();
dayBeforeYesterday.setDate(today.getDate() - 2);
Regards,
Ewan