POST
|
Due to a bug in Dashboard I need to be able to do updates to attributes without an objectid. So I changed my services to be "Supports ApplyEdits With Global Ids: true" but every time I try and do an applyEdits update of a feature with the globalid the error I am getting is "ObjectId field is missing."????? Anyone have a suggestions? Code below would work with Objectid var gUPDATE = {attributes: {GlobalID: "{A40352E3-0C1E-4A65-AAE7-106B4D79F131}", STATUS: "Pending"}}; featureLayer.applyEdits(null, [gUPDATE ], null, function (response) { console.log("done"); });
... View more
03-30-2020
07:12 AM
|
0
|
3
|
798
|
POST
|
That worked! Thanks Ken! Did a query to select all features then ran that array. Thank you
... View more
11-16-2016
08:02 AM
|
0
|
0
|
771
|
POST
|
Thanks For the Reply Robert, With the FeatureLayer.applyEdits is there a way to do all of the features at once or will I have to do each OBJECTID individually?
... View more
11-16-2016
05:47 AM
|
0
|
3
|
771
|
POST
|
I need to reset all the values in a field for all the features in a feature service. Just like the field Calculator in ArcMAP. Basically push a button and a whole field gets reset? Any ideas?
... View more
11-15-2016
01:37 PM
|
0
|
5
|
1113
|
POST
|
No too much work, they will be touching this script frequently in the field.
... View more
02-05-2015
06:46 AM
|
0
|
1
|
959
|
POST
|
Yes my script has no parameters so when a user click on it they see a parameters window that appears and no inputs to enter so they just hit Ok... I want to streamline the work flow and just remove the parameters window that appears.
... View more
02-04-2015
11:44 AM
|
0
|
3
|
959
|
POST
|
Is it possible/could someone show me what to add to a python script so that when it runs in ArcMAP the Parameters Window does not pop up? Thanks in Advance Paul
... View more
02-04-2015
11:33 AM
|
0
|
7
|
5136
|
POST
|
Does anyone know of a way to get the Lat/Long for a connected GPS device into python in ArcMAP. I cannot find a resource to do this? ArcMAP has GPS tools that allow me to view the GPS Position, so I know the data is in the program, just can't seem to isolate it? Thanks Paul
... View more
01-26-2015
01:26 PM
|
0
|
2
|
4537
|
POST
|
Is there currently, or for future roll outs, the ability to us a devices internal/bluetooth/USB GPS to locate ones self? Like the GPS tool in ArcMAP? Thanks Paul
... View more
01-05-2015
09:44 AM
|
0
|
0
|
4147
|
POST
|
I am trying to create a polyline from points collected via GPS... The last remaining piece is that when I try and post the points to polyline the code adds quotes around the coordinates and is causing the post to fail.
lineARRAY = lineARRAY.substring(0, lineARRAY.length - 1);
var linejs = "[[" + lineARRAY + "]]";
var singlePathPolyline = new esri.geometry.Polyline({"paths":linejs,"spatialReference":{"wkid":32054}});
var newAttributesG = dojo.mixin({}, GPSlayerLine.attributes);
var newGraphicL = new esri.Graphic(singlePathPolyline, null, newAttributesG);
GPSlayerLine.applyEdits([newGraphicL], null, null);
The resulting post is: [{"geometry":{"paths":[["[2498591.1952441176,335712.1545436013],[2498591.1952441176,335712.1545436013],[2498591.1952441176,335712.1545436013],[2498591.1952441176,335712.1545436013],[2498591.1952441176,335712.1545436013],[2498591.1952441176,335712.1545436013],"]],"spatialReference":{"wkid":32054}},"attributes":{}}]
As you can see it adds a double quote after paths (ex. "paths":[["[ ) Offending quotes in red? Any idea on how to alter the attached code so I can eliminate the addition of those quotes? Thanks
... View more
08-21-2014
08:41 AM
|
0
|
1
|
440
|
POST
|
Anyone else encounter this? I need to order some tablets soon, do Android Tablets have this issue?
... View more
03-28-2014
09:57 AM
|
0
|
0
|
195
|
POST
|
Here is the FULL working code... click the button on the lower left of the map, then click the map. alert will pop up. click the map again. No alert. <!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=7, IE=9">
<title>mapMUSKEGO | mapVEPRASKAS</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<link rel="stylesheet" href="http://js.arcgis.com/3.6/js/dojo/dijit/themes/claro/claro.css">
<link rel="stylesheet" href="http://js.arcgis.com/3.6/js/esri/css/esri.css">
<style type="text/css">
html,body,#map{
padding:0;
margin:0;
overflow:hidden;
height:100%;
background-color:#dbddda;
}
</style>
<script src="http://js.arcgis.com/3.8/"></script>
<script>
dojo.require("esri.map");
var map;
var initExtent;
var buttonclick;
function init() {
initExtent = new esri.geometry.Extent(2485078.859947771, 312461.2599477768, 2517629.6100261062, 344895.2419843375, new esri.SpatialReference({ "wkid": 32054 }));
map = new esri.Map("map", { extent: initExtent, logo: false, slider: false});
var greyMAP = new esri.layers.ArcGISDynamicMapServiceLayer("http://sampleserver6.arcgisonline.com/arcgis/rest/services/Census/MapServer", { });
map.addLayer(greyMAP);
}
function buttoncall() {
buttonclick = dojo.connect(map, "onClick", resultFunction);
}
function resultFunction() {
dojo.disconnect(buttonclick);
alert("test");
}
dojo.ready(init);
</script>
</head>
<body>
<div id="map"></div>
<a href="javascript:buttoncall()" id="button1" ><img alt="button1IMG" id="button1IMG" style="bottom:10px; left: 10px; width:36px; position:absolute; z-index:22; border:none;" src="images/Button.png"/></a>
</body>
</html>
... View more
03-26-2014
05:49 AM
|
0
|
0
|
145
|
POST
|
Sorry I missed a coma....
buttonclick = dojo.connect(map, "onClick", resultFunction);
... View more
03-25-2014
01:28 PM
|
0
|
0
|
615
|
POST
|
In the HTML create a button that calls the function buttoncall
<a href="javascript:buttoncall()" id="button1" ><img alt="button1IMG" id="button1IMG" style="bottom:10px; left: 10px; width:36px; position:absolute; z-index:22; border:none;" src="images/Button.png"/></a> The map onClick will then stay activate until in your code you set it disconnect dojo.disconnect(buttonclick);
... View more
03-25-2014
01:19 PM
|
0
|
0
|
615
|
POST
|
This should work for either one... Create a global variable var buttonclick; Then create the function the button calls function buttoncall() {
buttonclick = dojo.connect(map, "onClick" resultFunction);
}
function resultFunction() {
dojo.disconnect(buttonclick);
alert("test");
} Give it a shot
... View more
03-25-2014
05:27 AM
|
0
|
0
|
615
|
Title | Kudos | Posted |
---|---|---|
7 | 09-12-2022 08:50 AM | |
3 | 04-14-2021 07:49 AM |
Online Status |
Offline
|
Date Last Visited |
2 weeks ago
|