首页 / 浏览问题 / WebGIS / 问题详情
测量面积和距离时候出现错误
6EXP 2020年07月22日
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)

1个回答

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

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

3,357EXP 2020年07月24日
...