How to resolve the error Unexpected "=" at character
Got feedback or spotted a mistake?

Leave a comment at the end of this page or email contact@krishagni.com

How to resolve the error Unexpected "=" at character

Why did this error happen?

In older versions (before v11), the '=' operator was used in the showWhen condition for skip logic. However, this is incorrect because = is used to assign a value, not to compare values.

From v11 onwards, OpenSpecimen uses the correct comparison operator ‘==’ in skip logic. Using = will cause an error in newer versions.

For more details, please refer to this wiki page.

Example: Show a field when the specimen class is “Cell”

Old syntax:

$extendedObj.specimenClass = "Cell

New syntax:

specimen.specimenClass == "Cell"

Solution:

Always use == (double equal sign) in the showWhen condition inside the form XML to compare values and avoid this error.

 

Got feedback or spotted a mistake?

Leave a comment at the end of this page or email contact@krishagni.com