Avatar

Correct answer by
Employee Advisor

After a lot of testing trial and error, the following worked; it was the xpath was wrong.

 

  var recipientId = 13241267;
  var x  = sqlGetMemo('SELECT mData FROM nmsRecipient WHERE iRecipientId ='+recipientId);
  var y  = DOMDocument.fromXMLString(x);
  var z  = y.root.getValue('/changes/@firstName'); //now works
  var za = y.getElementsByTagName('recipient')[0].getValue('/changes/@firstName'); //now works

View solution in original post