5.8.2. Advanced Scripting

setTag() does accept optional parameter whereby a virtual tag's time stamp can be altered for database logging purpose. setTag( 'tag', data, option); Where the option is a JSON object that has a time item accepting Javascript Date(). A complete sample can be seen in the following snippet.

var opt = {
  "time" : new Date(
  2020, //yyyy
  0, //M; 0: Jan, 1: Feb...
  1, //D
  1, //h
  2, //m
  3, //s
  456//msec
  )
};
setTag( "myTag", 123.45, opt);