var startDate = “23-SEP-2022”;
startDate = new Date(startDate.replace(/-/g, “/”));
var endDate = “”, noOfDaysToAdd = 2, count = 0;
while(count < noOfDaysToAdd){
endDate = new Date(startDate.setDate(startDate.getDate() + 1));
if(endDate.getDay() != 0 && endDate.getDay() != 6){
count++;
}
}