Hot answers tagged

2

This blog has an excellent example of how to make the window draggable and hide the arrow using dojo: https://gavinr.com/2015/04/13/arcgis-javascript-draggable-infowindow Here's the key javascript snippet: require([ 'esri/arcgis/utils', 'dojo/dnd/Moveable', 'dojo/query', 'dojo/on', 'dojo/dom-class' ], function ( arcgisUtils, ...


1

i wrote a blog on this exact topic awhile back. Using Proj4JS in the ArcGIS API for JavaScript to reproject coordinates on the fly https://geonet.esri.com/groups/geodev/blog/2014/11/03/use-proj4js-alongside-the-arcgis-api-for-javascript-to-reproject-coordinates-on-the-fly


1

Reading the docs : https://developers.arcgis.com/javascript/3/jsapi/featurelayer.html#event-load In JavaScript if code is asynchronous, should be provided an event / callback function that fires once the code is done. It seems there's a load event. So, try something like this : featureLayer.on('load', function(response){ ...


1

You may not be able to do that using the where clause. In the link you provided, the docs say "Some of these options may be overwritten by the search widget including the following:" outSpatialReference returnGeometry num outFields where maxAllowableOffset objectIds


1

I ended up doing it manually since I haven't found how to do it... var polygons = []; var i; for (i = 0; i < featureLayerSelection.graphics.length; i++) { polygons[i] = new Polygon(new SpatialReference(featureLayerSelection.graphics[i].geometry.spatialReference.wkid)); polygons[i].rings ...


1

As far as i know, the ArcGIS API for JavaScript doesn't have a handy shorthand to bump LODs on the fly but you can supply an altered set yourself. tileInfo: new TileInfo({ spatialReference: new SpatialReference({ "wkid": 3857 }), rows: 512, cols: 512, origin: { "x": -20037508.34, "y": 20037508.34 }, lods: [ ...


1

You got this error because you are trying to get an Extent of point geometry , so the Point geometry does not have an extent like (polyline,polygone ...) the school feature layer is a esriGeometryPoint Layer , so you cant work with extents here : I used the centerAndZoom map function to zoom to the returned point geometry , and i've add graphic for ...


1

Based on this thread it appears that this is a limitation of the print task API. The ESRI staff member there stated: Unfortunately, i don't know how of a good way to work around this problem (other than ensuring that you have fields present in the data for values you need to render by.)



Only top voted, non community-wiki answers of a minimum length are eligible