如何修复此SyntaxError:意外的标识符?

时间:2015-03-11 06:45:09

标签: javascript

on.pitch = event.value+GetParameter('Starting Note'+' 'event.channel)+GetParameter('Number'+' 'event.channel)*12;

错误是:

[JS Exception] SyntaxError: Unexpected identifier 'event'. Expected ')' to end a argument list. line:4

如何解决此问题?

1 个答案:

答案 0 :(得分:1)

删除event之前的单引号:

on.pitch = event.value+GetParameter('Starting Note '+event.channel)+GetParameter('Number '+event.channel)*12;