On mouse click dbtag=opctag

I would like to setup [del]an expression[/del] [color=#0000FF]a script[/color] on a mouse click that copies the data value from an OPC tag to a DB tag but I’m not sure the correct syntax.

opcValue = system.tag.getTagValue("[]OPCTag") system.tag.writeToTag("[]DBTag",opcValue)

Thanks Kyle