<head>
...
//删除
function DoDelete(flag)
{
GetItemId(flag);
}
function GetItemId(flag)
{
var items = Co["DispDataList"].GetSelected();
var sid = "";
if (items.length == 0) {
alert(WARNINGSTRING);
return;
}
else {
sid = items[0].GetAttr("Id");
}
var fType = (flag == "Modify") ? "Modify" : "Delete";
LinkTo("PosEdit.aspx?FuncType=" + fType + "&Id=" + sid,BLANK,WINDOWSSIZE);
}
..
</head>
<form>
.... //解决用单引号传值
<button id="btnAdd" onclick="DoDelete('Delete')" type="button"
jctype="jcbutton">添加</button>
....
</form>