Where are you getting the error? At the machine or when posting code?
The onParameter function shows some Actions that should be used.
function onParameter(name, value) {
var invalid = false;
switch (name) {
case "action":
if (String(value).toUpperCase() == "PARTEJECT") {
ejectRoutine = true;
} else if (String(value).toUpperCase() == "USEXZCMODE") {
forceXZCMode = true;
forcePolarMode = false;
} else if (String(value).toUpperCase() == "USEPOLARMODE") {
forcePolarMode = true;
forceXZCMode = false;
} else {
var sText1 = String(value);
var sText2 = new Array();
sText2 = sText1.split(":");
if (sText2.length != 2) {
error(localize("Invalid action command: ") + value);
return;
}
if (sText2[0].toUpperCase() == "TRANSFERTYPE") {
transferType = parseToggle(sText2[1], "PHASE", "SPEED");
if (transferType == undefined) {
error(localize("TransferType must be Phase or Speed"));
return;
}
} else if (sText2[0].toUpperCase() == "TRANSFERUSETORQUE") {
transferUseTorque = parseToggle(sText2[1], "YES", "NO");
if (transferUseTorque == undefined) {
invalid = true;
}
} else if (sText2[0].toUpperCase() == "USETAILSTOCK") {
forceTailStock = parseToggle(sText2[1], "YES", "NO");
if (forceTailStock == undefined) {
invalid = true;
}
} else if (sText2[0].toUpperCase() == "SYNCSPINDLESTART") {
syncStartMethod = parseToggle(sText2[1], "ERROR", "UNCLAMP", "SPEED");
if (syncStartMethod == undefined) {
invalid = true;
}
} else {
invalid = true;
}
}
}
if (invalid) {
error(localize("Invalid action parameter: ") + sText2[0] + ":" + sText2[1]);
return;
}
}