Use this tag when ArcGIS API for JavaScript is the web mapping API that you are using from the ArcGIS platform.

learn more… | top users | synonyms

2
votes
2answers
6k views

Drawing circle of specified radius in meters using ArcGIS API for JavaScript?

I am trying to add a circle of a specified radius (let's say 200 meters) to a map. My thought is to create a SimpleMarkerSymbol object. The constructor asks for a size of the symbol in pixels, but I ...
0
votes
0answers
8 views

Javascript Manipulating Display Of WMSLayer

Is there a way to change the map display color for a esri WMSLayer? The only interactive method that is similar to what I am trying to do is setOpacity() var wmsLayer = new WMSLayer(wms, { ...
3
votes
1answer
60 views

Arcpy geoprocessing script running with default inputs

I have a pretty simple geoprocessing script. My javascript is supposed to be passing it a list of layers to query. Something like this for the Javascript: var params = { "Layers": ...
1
vote
0answers
46 views

Trying to query based on selected feature, but query is using previously selected feature

I'm not sure how to replicate this problem with just a code snippet, because it involves so many different elements of my HTML and JS. So here is a jsbin with the whole code. I use ESRI's popup ...
1
vote
0answers
37 views

ESRI Javascript KMLLayer and CSVLayer

I have a map where I have a KMLLayer that defines a geographic boundary and a CSVLayer that defines points within that boundary. I do not want any infoWindow information popping up for the KMLLayer ...
3
votes
2answers
50 views

How to pass arguments to query function in different module

I have a query (see this jsbin example) to find the percentile rank of a fields value. So it finds all records (N) and then how many records are less than itself (k). Percentile = k/N as a rounded ...
0
votes
0answers
27 views

QueryTask with StatisticDefinition throws Error: Unable to complete operation

I'm trying to run the following query on my layer, which is on ArcServer 10.1 and has outStatistics = true. My syntax all looks right to me. As I said above, I get Error: Unable to complete ...
2
votes
1answer
364 views

GGeoXml error with Arcgis extension for google maps api [closed]

I'm using the ArcGis google maps extension. I've created a simple page based on the esri example here... I have successfully buffered a polyline, however, when I create a query and execute the ...
1
vote
0answers
30 views

Info template displayed far from mouse click

I've consistently noticed in my ESRI webmap that the info template is displayed below the mouse click. For example, if I click on a polygon the one below it is displayed. Sometimes, I cannot get the ...
0
votes
1answer
46 views

ESRI Javascript CSVLayer onClick Event

I have a CSVLayer that I loaded into a web application. The data that I want to display within the infowindow of that CSVLayer is too large to display nicely in the existing map window. Therefore ...
6
votes
3answers
2k views

How to share a hosted feature service with an application on ArcGIS Online?

According to the ESRI REST API documentation on authentication, a registered application can log in to AGOL via an App ID and App Secret and will then have access to the data that has been shared with ...
1
vote
0answers
48 views

How to correctly display SVG path graphic after map scale change using ESRI JavaScript API?

I've built a web map that shows the locations of fleet vehicles based on their GPS data. I managed to add a nice feature that animates the routes these vehicles take on their way to destinations using ...
0
votes
1answer
32 views

InfoWindow.getSelectedFeature() not working

When I select a geometry on map, the method map.infoWindow.getSelectedFeature() always returns "undefined". It looks like it is not working. This behavior is with InfoWindow and also with Popup. Also ...
2
votes
1answer
48 views

ArcGIS network analyst JavaScript API “No Facility found” error

I am using below code for ArcGIS SERVER Network Analyst API: ArcGIS JavaScript API for Network Analyst I need to customize it for my own NA server. I have successfully created an NA-SERVER on ArcGIS ...
2
votes
2answers
46 views

ESRI JS API - Unable to register Basemap Gallery (ID is already registered)

I am attempting to add a BasemapGallery to my web application. I prefer to create my layout dynamically using constructors such as: layout.cpRight = new ContentPane({ region:"right", ... ...
0
votes
1answer
1k views

How to determine the accuracy of getFeatureInfo on a WMS layer?

I have added a WMS layer to the ArcGIS Server JSAPI and am attempting to query it using getFeatureInfo when the user clicks on the map. This is mostly working, except that the accuracy of the ...
1
vote
0answers
25 views

Showing only legend items that are actually displayed within current map extent using ArcGIS API for JavaScript?

I'm using TOC/Legend widget as a default legend panel in my ArcGIS based JavaScript API web app. It works great, beside now i want to filter this legend panel based on users current map extent. The ...
0
votes
1answer
35 views

Using Click Event on Layer A to query Layer B in ArcGIS API for JavaScript?

I have two polygon layers in a webmap service and want to do a dynamic query on click, such that when the user clicks on a lake (layer A) with ID = 100, the corresponding watershed boundary (layer B) ...
4
votes
2answers
83 views

ESRI JavaScript API - Add Layer using esriRequest Response

For various reasons I need to add layers to a map object using a response returned by an esriRequest to an ArcGIS Server. One reason being the data will change constantly and hard coding FeatureLayer ...
0
votes
1answer
28 views

Arcgis Javascript Api Identity Manager with proxy

I'm trying to setup an authentication architecture with a web app using arcgis Javascript api with a configured .NET proxy and a web adaptor. When i load my app the identity manager shows up for ...
0
votes
1answer
24 views

Setting color info without defining new instance of renderer

I have an esri map with five feature layers. Each also has an id, and it is used in a toggle layer function to update layer visibility in the map. For most layers, I just need to set one static color ...
3
votes
0answers
211 views

Increase maximum zoom level for a WebTiledLayer in ArcGIS

I am using the WebTiledLayer from the Javascript ArcGIS API to render a custom WMTS source. The WMTS I am using has zoom levels going from 18 to 21, however I cannot zoom in further than what appears ...
-1
votes
1answer
47 views

how to highlight map area with extent geometry onmouse click

I got this example in arcgis api ssample code . But the problem is that , i want to create it for any area of map . like if one click on any city , it should be selected.And the code is for mouse-over ...
-1
votes
1answer
54 views

Uncaught TypeError: registry.forEach is not a function

I am trying to add two dojo buttons for polyline and rectangle on a map, and i have written loop for two buttons, but i am getting error :"Uncaught TypeError: registry.forEach is not a function" ...
0
votes
1answer
54 views

Geosearch Esri controls in leaflet

It is possible to disable the Geosearch Esri controls in leaflet after the first geocode search? When I run Chrome console and I select the search geocode icon this is the code: <input ...
1
vote
1answer
52 views

Configurable Map Viewer (CMV) Measurement Widget Error

I have several cmv widgets enabled, some I have built myself. All work great, but when I enable the Measurement widget I am getting this error upon loading the app: dojo/parser::parse() error ...
1
vote
1answer
45 views

Is there a way to get the vertices of segment of polyline?

I have a polyline with 3 co-ordinate, say (x1,y1), (x2,y2), (x3,y3). Can I get the vertices (x1,y1), (x2,y2) if clicked on line-segment drawn by (x1,y1), (x2,y2). I have a polyline on map that with ...
0
votes
1answer
53 views

Not able to remove layer from map

I am using arcgis javascript api . I want to remove a recently added layer , i wrote like this var a = map.layerIds; var b = map.getLayer(a[2]); map.removeLayer(b); But I am not able to remove any ...
1
vote
0answers
30 views

Highlighted graphics resets on zoom in ArcGIS API for JavaScript?

I am highlighting graphic using graphic.setSymbol(pictureSymbol). It is working fine. But, when map is zoomed the symbol graphic is reset to default. If anyone has come over the issue, please help! ...
0
votes
1answer
59 views

zoom to all points in arcgis js api

Can anybody tell me what wrong in this code.Here I am passing point geometry to query task. var districtName = $('#ddlDistrictd').val(); function showresults() { $.ajax({ type: "POST", ...
0
votes
1answer
42 views

Table of Contents(TOC) Widget for ArcGIS JavaScript API in Legacy?

I want to develop a legend using Table of Contents(TOC) Widget for ArcGIS JavaScript API in Legacy code. I have tried its development by following the steps in the documentation of TOC Widget for ...
0
votes
1answer
144 views

Esri API JS, popup not displaying after first click [duplicate]

Demographics data shows upon first click but not after, park information does work. I've changed around almost everything with non real solution. I feel like for whatever reason my feature server data ...
0
votes
0answers
58 views

Zoom to x y coordinates in arcgis javascript api 3.15

I am using arcgis javascript Api 3.15 with ASP.NET and Ajax.I got json object contains only x and y coordinates. This object does not have geometry column. How can I zoom to this json object. Should I ...
3
votes
1answer
46 views

Show coordinates in other projections (ArcGIS Javascript API)

Is it possible to change this sample that it will be show x,y coordinates in wkid:5514 ? <meta name="viewport" content="initial-scale=1, maximum-scale=1,user-scalable=no"> ...
0
votes
1answer
51 views

checkbox in toc is not working

I have toc with dynamic and feature layers.its displaying properlybut when I checked on and off the checkbox nothing is changing on layer. below is code: <!DOCTYPE html> <html> ...
1
vote
1answer
659 views

Geoprocessing tool not executing when Map's SpatialReference is Web Mercartor

I am facing a strange issue when trying to execute GP service when my map's spatial-reference is Web Mercator. I appreciate all help. I have a JavaScript API application. Initially I only had my map ...
0
votes
0answers
26 views

Why is BorderContainer and ContentPane methods are not called for map and attributeInspector elements using ArcGIS API for JS?

I'm trying to display the attribute inspector on right-side panel when a feature 'onclick' event is called, but whenever i click on a feature the attribute inspector shows-up on left-side of the ...
0
votes
2answers
125 views

Uncaught SyntaxError: Unexpected token (

I want to show tooltip for my dojo button, I have tried the following code but getting error: Uncaught SyntaxError: Unexpected token (. Please solve this issue. <!DOCTYPE html> <html> ...
1
vote
1answer
57 views

query.where statement using date range in JS API fails with IE 11 but works fine with Chrome and Firefox

My aim to display point data from a feature layer on ArcGIS for JS map interface. I am successful doing so in Chrome and Firefox, however when I include date in a where condition of a query execute it ...
0
votes
2answers
93 views

draw polyline on map in javascript api

I am trying to draw polyline on map, but line is not adding to the map,please help me determine where I am making a mistake. <!DOCTYPE html> <html> <head> <meta ...
2
votes
1answer
90 views

TypeError: g.join is not a function in queryTask.execute

I need to query data from a server, so I try to exploit "Query data without a map" sample. However, at queryTask.execute I get following error: TypeError: g.join is not a function My code is ...
3
votes
2answers
122 views

How to pass polygon to query.geometry with ArcGIS API for JavaScript

I have to highlight district boundary and corresponding point. So I am trying to do like below code. But I don't know how to pass district polygon geometry to query.geometry. var queryTask = new ...
0
votes
2answers
75 views

Take URL Parameters including corner Coords in ArcGIS webmap and display polygon on launch

I have a list of corner coords for study areas in a sharepoint list. I used 'calculated field' to generate a url that launches our internal webmap in a new window and sets the extents as the ...
4
votes
1answer
152 views

Options to Replace Interactive Mapping System

I have been tasked with replacing our organizations online interactive mapping system. It is your run of the mill County Government interactive map. Its bulky, unreliable, slow and out of date. It is ...
-1
votes
1answer
106 views

Python or Javascript focus (for self-directed study at university) [closed]

Next semester is my last at university. I have taken all 3 of the GIS courses offered in my program. Besides some very light interaction with Python though, their has been zero discussion of ...
0
votes
0answers
25 views

How to show a legend of a invisible layer in ArcGIS javascript?

Using the JavaScript API for ArcGIS, I'd like to show the legend of a DynamicMapServiceLayer that's not visible. Is this possible? The result would be a static legend that's always there, no matter ...
1
vote
1answer
44 views

configurable map viewer multiple map services

I have multiple map layers (right now about a dozen but that will likely stretch to several dozen) in my CMV. I have introduced several WMS services to operationalLayers that I have published to a ...
0
votes
1answer
27 views

Setting opacity info in ArcGis Api for Javascript overwrites featureLayer.renderer.colorInfo

I'm having trouble setting the color of a feature layer in ArcGIS api for javascript. I have a feature layer, which, on the load event I set its renderer's colorInfo and opacityInfo. Both work ...
0
votes
0answers
19 views

Editing dijits which honor subtypes

Does only the attribute inspector honor subtypes? Referring to API doc https://developers.arcgis.com/javascript/jsapi/attributeinspector-amd.html I have lately started using the Web App Builder ...
1
vote
0answers
22 views

How to set snapping specification in web map feature layer (arcgis)?

I need to set snapping to snap just to polygon vertex (by default it snaps to polygon vertex and edges). In this example and according to this, the map.enableSnapping() function should return an ...