Trying to update an existing case after a new communication comes in for a case.
Trying to do this in CreatComm function however it doesn't work and gives error on line ExecSql().
Any help would be appreciated.
function CreateComm(bNotify)
.......
if (bNotify)
{
var commdate = new Date();
mydate = commdate.getVarDate();
comm("Comm_NotifyTime") = mydate;
var StrSql = "SELECT * from Cases where Case_ReferenceID='"+ + mycase + "'";
var casrec;
casrec = eWare.CreateQueryObj(StrSql);
casrec.SelectSql();
var stage = "Active";
var sql = "UPDATE Cases SET case_notifytime = " + mydate + ", case_stage =" + stage + ", WHERE Case_ReferenceID='" + mycase + "'";
var UpdateQuery = eWare.CreateQueryObj(sql);
UpdateQuery.ExecSql();
}