you can use simple UDF to create this...
public String getDate(Date idocDt, int dateCounter) {
String formatted = null;
try{
Calendar c =Calendar.getInstance();
c.setTime(idocDt);
c.add(Calendar.DATE,dateCounter);
SimpleDateFormat format1 =newSimpleDateFormat("yyyy-MM-dd");
formatted = format1.format(cal.getTime());
} catch(Exception e){e.printStackTrace();
formatted = "";
}
return formatted;
}
pass the idoc date in the first argument for the above method.
Pass values 1 for BeginDate in the dateCounter and 7 for EndDate.
add import statement as follows..
import java.util.*;
import.java.text.*;
Message was edited by: Baskar Gopalakrishnan