AnsweredAssumed Answered

before-apply-edits server error

Question asked by deleted-user-x7XmeRtVHyGE on Jan 31, 2017
Latest reply on Feb 6, 2017 by deleted-user-x7XmeRtVHyGE

Hello all,


I've implemented the following code using a before-apply-edits on a layer, however I get an error when I try to apply those changes I made using a geometry service. The server does send an error 17000 on the Method "GraphicFeatureServer.HandleREST_ApplyEditsOperation". Any help is much appreciated. This is a head scratcher for me.


          forage.on("before-apply-edits", function (evt) {
                if (evt.adds != null){


                var query = new Query();
                query.outSpatialReference = map.spatialReference;
                query.geometry = evt.adds[0].geometry;
                query.spatialRelationship = Query.SPATIAL_INTERSECTS;
                var feat = evt.adds[0];
                property.queryFeatures(query, function(featureSet) {
                    if (featureSet.features.length == 0) {
                    else {
                        console.log("pboundary detected");
                        var intersectGeometry = feat.geometry;
                        var queryGeometry = featureSet.features[0].geometry;
                        var newGeom = geometryEngine.intersect(intersectGeometry, queryGeometry);
                        forage.applyEdits(null, [feat], null);