Forum Discussion
java script not definied
- 7 months ago
That often means there is some syntax error such as mismatched quotes, braces, parentheses, etc. Is the alert statement above copied directly from your script, or did you retype it? Make sure the quotes are actually plain quotes, not the curly quotes you often get when copying text from Word or the web.
Try disabling the script containing that statement and see if it works without error to make sure the error is actually there and not somewhere else.
Try starting over with the original working project file and add only small bits of javascript to ensure each piece works before adding more if you have troube narrowing it down.
Also, try pasting your JS code into https://jshint.com/ to check for erorrs before putting it into you SL trigger.
That often means there is some syntax error such as mismatched quotes, braces, parentheses, etc. Is the alert statement above copied directly from your script, or did you retype it? Make sure the quotes are actually plain quotes, not the curly quotes you often get when copying text from Word or the web.
Try disabling the script containing that statement and see if it works without error to make sure the error is actually there and not somewhere else.
Try starting over with the original working project file and add only small bits of javascript to ensure each piece works before adding more if you have troube narrowing it down.
Also, try pasting your JS code into https://jshint.com/ to check for erorrs before putting it into you SL trigger.
Related Content
- 8 months ago
- 5 months ago