测量面积和距离时候出现错误

0 投票
test8.js:42 Uncaught SyntaxError: missing ) after argument list
test37.js:17 Uncaught TypeError: Cannot read property 'addLayers' of undefined
    at initialize.addLayer5 (test37.js:17)
    at initialize.triggerEvent (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:23554)
    at initialize.getStatusSucceed (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:138859)
    at initialize.triggerEvent (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:23554)
    at initialize.getMapStatusCompleted (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:554504)
    at initialize.getUrlCompleted (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:534238)
    at eval (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:1792)
    at Object.runCallbacks (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:26936)
    at d.f.onreadystatechange (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:26288)
    at d.c.dispatchEvent (eval at <anonymous> (SuperMap-8.1.1-17729.js:3), <anonymous>:1:31341)
7月 22 分类:  52次浏览 | 用户: Lynch (6 分)
重新分类 7月 24 用户:程逸诗

1个回答

0 投票

您好,从您的报错上看,是您在代码写法上出现的问题,请您排查下  是不是您少写了(),{}等。您可以参考示例https://iclient.supermap.io/examples/classic/editor.html#controler_distanceMeasure

https://iclient.supermap.io/examples/classic/editor.html#controler_areaMeasure

7月 24 用户: 阳俊林 名扬四海 (3,296 分)
...