I use this xsnippet all the time and the problem in your code is that you are using an vector to add the names in. Try to add the names in a Javascript array instead. Like this
import ss_html_mail;
var mail = new HTMLMail();
var res=[]
res.push("Soundararajan, Thirun");
res.push("Arumugam, Barath");
res.push("Selvam, Abirami")
res.push("Panneerselvam, Saravanan")
mail.setTo(res);
mail.setSubject("HTML Mail");
mail.addHTML("HTML Mail");
mail.send();