SyntaxError: illegal character error message during replay of Evaluate JavaScript step in TruClient script

  • KM01007676
  • 23-Jun-2014
  • 25-Jul-2014

Summary

Not English characters in TruClient protocol functions cause an "illegal character" or "invalid character" error message.

Error

During replay of TruClient protocol function in LoadRunner the following error message is displayed:

Evaluate JavaScript code var myGlobalVar=LR.getPa...t(myGlobalVar); ** failed - exception occurred: SyntaxError: illegal character

the error message could also be:

"SyntaxError: Invalid character    [MsgId: MERR-203252]."

Cause

The function contains a not English character.

In the example

var myGlobalVar=LR.getParam(“myParam";

the character in  (myParam")  is not written using English keyboard which will cause the error message.

Fix

Make sure that the TruClient functions are written using only English characters.