you could create an array of dates. I am rusty and I would double check my syntax.
local stringvar dateList:="";
local numbervar xx:={PR.DATE_CLOSED}-{PR.DATE_OPENED};
shared datetimevar array result(xx); //I think this initializes the array for xx elements
local numbervar i:=0;
for i:=1 to xx+1 do
(
dateList:=dateList+left(totext(aDate),10); //,"mm/dd/yyyy");
result := aDate; //assign the date to the array
local datetimevar aDate:=dateadd("d",1,aDate);
);
dateList;
//don't need to return the date array as it is shared and can be accessed from anywhere in the report.
HTH