8.7w+
社区成员
line = document.createElement("v:polyline");
if (id != "") line.id = id;
//line.style.position="absolute";
line.points.value = sp[0] + "," + sp[1] + " " + ep[0] + "," + ep[1];
line.setAttribute("fromTo", sp[0] + "," + sp[1] + "," + ep[0] + "," + ep[1]);
line.strokeWeight = "1.2";
line.stroke.EndArrow = "Block";
line.style.cursor = "crosshair";
if (id != "" && id != "GooFlow_tmp_line") {
var text = document.createElement("div");
//text.innerHTML=id;
line.appendChild(text);
var x = (ep[0] - sp[0]) / 2;
var y = (ep[1] - sp[1]) / 2;
if (x < 0) x = x * -1;
if (y < 0) y = y * -1;
text.style.left = x + "px";
text.style.top = y - 6 + "px";
line.style.cursor = "pointer";
}
if (dash) line.stroke.dashstyle = "Dash";
//if (mark) line.strokeColor = "#ff3300";
//else line.strokeColor = "#5068AE";
if (mark) line.strokeColor = "#ff3300";
else line.strokeColor = "#000000";
return line;
line.points.value = sp[0] + "," + sp[1] + " " + ep[0] + "," + ep[1];
0x800a138f - JavaScript 运行时错误: 无法设置未定义或 null 引用的属性“value”
<!--[if lt IE 9]>
<?import namespace="v" implementation="#default#VML" ?>
<![endif]-->
<link rel="stylesheet" type="text/css" href="../codebase/GooFlow2.css" />
line = document.createElement("v:polyline");
document.body.appendChild(line);
if (id != "") line.id = id;
//line.style.position="absolute";
line.points = sp[0] + "," + sp[1] + " " + ep[0] + "," + ep[1];
加上了红色的话 然后去掉 line.points.value 中的value 不报错了 ;但是下面还是有错:line.stroke.EndArrow = "Block";错误转移到这里了 还是一样的错