Tag Info

New answers tagged

0

In theory you could use the supported Query interface on this Service Layer to download the geometries: http://watersgeo.epa.gov/arcgis/rest/services/NHDPlus_NP21/WBD_NP21_Simplified/MapServer/0/query But this seems like it might not be the best idea. Following the full metadata link (http://www.horizon-systems.com/nhdplus/NHDPlusV2_home.php) you can get ...


1

The OpenStreetMap tiles are pre-rendered in Web-Mercator (i.e. EPSG:3857) and hence you can't get them in your projection, and show it in this map. You have two options: Tile your data in Web Mercator Download OSM data, and then create tiles for it your Projection.


0

Koop might be an option here. It has the ability to create custom providers. Not sure if WFS is an out of the box provider but the dev team is very active and might help build one if asked. https://github.com/Esri/koop


1

This question is a month old so you may have already found options. The Configurable Map Viewer (CMV) sounds like it may meet your needs. CMV is built on top of the ArcGIS API for JavaScript. It is open source so you can edit and tweak if you need something more than what can be configured within the configuration files. We have recently added a number of ...


2

You can combine the two layers as a single Basemap and pass them to the map constructor. Below is a full working example using the two layers you are interested in. This came from a discussion we had over on github related to using non-mercator maps as basemaps for the Configurable Map Viewer (cmv) that is based on the ESRI JS API. This does not fully ...


1

You can only use the Esri pre-canned basemaps ("streets", "satellite", "topo", etc.) in the constructor. If you search the Esri JavaScript code, you can find "Streets" and "Satellite" basemaps defined in the code, but not "Terrain". You don't actually have to specify a basemap in the constructor. In the code example below, I am adding the streets basemap ...


1

When solving it programmatically I would start with this Snippet from ESRI: Create Graphic Buffers around Selected Features Snippet: ///<summary>Draws graphic buffers around the selected features in the map using distance units specified.</summary> /// ///<param name="activeView">An IActiveView interface.</param> ///<param ...


4

Creating a 3km radius circle is quite easy in ArcGIS: Create a point featureclass marking the center of your area of interest. Use the Buffer (Analysis) tool to create the 3km radius buffer around the point featureclass.


0

Assuming that your feature layer can only be edited via the ArcGIS Server JS API, you can attach a listener to the edits-complete event. This will fire when the user makes any edit. You'll need to write the code to evaluate what to do at this point. For example, evaluate the edit, and if it has been a change from Pending to In Progress, then notify the ...


1

The map reference lists the available basemaps which can be specified using the keyword: Valid values are: "streets" , "satellite" , "hybrid", "topo", "gray", "oceans", "national-geographic", "osm". You can add other layers as a basemap by finding their REST endpoint and adding them as a tiled layer. There's a example script here. The Esri Terrain layer ...


0

If you look at the documentation for the map.centerAndZoom function, you'll find that it requires both a point and a zoom level. Because it doesn't know how far to zoom in, it can't establish a "left" bound, "right" bound, or any bound. That is why it mentions the "left" property. Try this instead setTimeout(function () { map.centerAndZoom(point, 12); ...


0

I usually get this when something is null along the way (browser fails, no message, hard to debug); My suggestion is to start by hitting F12 for the debug tools (chrome, FF, IE all use this), put a breakpoint at the start of your id results function and inspect your variable (mouse over or add a watch). I'd personally make a few style changes but my main ...


3

The map object will take on the projection of the first layer you add to it, in the case of your code, the streets basemap is 102100 (web mercator). You have two options to solve this: Use your own basemap service that is in your 102726 projection so that the points from the web service show up in the correct place. Stick with arcgis online basemaps, ...


1

The answer depends on how robust your KML reader is and what you want to do. I downloaded both kmz files and renamed each file to .zip like you did. They are just zip files after all. I took the section of the code you posted above from <Folder> ... </Folder> and put it in the MD1558.kml file right after the MD1558.kml ... </Folder> ...


-1

var populateList = function(results) { //Populate the ComboBox with unique values var zone; var values = []; var testVals = {}; //Add option to display all zoning types to the ComboBox values.push({name: "Select District"}) //Loop through the QueryTask results and ...


0

I must've missed it in the APi documentation. There is a function called singleThumbAsTimeInstant(createTimeInstants) for the time slider. Once you set this to true, then it will only display items at that specific time. The documentation is here.


-1

Thanks a lot for your responses. I found the answer. The trick is to know the graphic that coresponds to the geometry. So you olny have to use : map.graphics.remove(your_graphic);


1

If the Graphic is added directly to the map, you can just call map.graphics.remove(the_graphic), where the_graphic is the graphic that you want to remove. You can also call map.graphics.clear(); to remove all graphics added in this way. If you have added graphics to a particular graphics layer, then you need to remove the graphic from that particular ...


0

It sounds like you're working with graphics elements on the map, which were added using the Editor toolbar. In this case, the graphics are probably located in the map's default graphicsLayer, or in another graphics layer. See map.graphicsLayerIds for a method to iterate through these layers. Once you have a pointer to the graphic via its layer, you can ...


1

So, after consulting here and on ESRI's GeoNet, I have come to the conclusion that for some reason ArcGIS Server 9.3.1 does not pass the information to the JavaScript API that I require. A user on GeoNet compared their up-to-date server against my slightly aged one. They have the required properties while I do not. Just another reason to convince my boss ...


0

sounds like you should be listening to the map's 'click' event and calling a method like centerAndZoom(), passing in the mapPoint that is returned by the event and whatever zoom level you think would be appropriate.


1

If you don't plan on maintaining/upgrading a web application, its typically a good idea to leave the services that it utilizes alone as well. Because version 1.4 of the Esri JavaScript API was released years and years before ArcGIS Server was re-engineered/redesigned in its current native 64 bit form, there was no way for the developers to ensure that it ...


0

Another way to get the layers in the webmap is through arcgisUtils.getLegendLayers(). It generates a list of objects that include the title from ArcGIS Online, and the layer. Here's a snippet of what I would use accomplish what you're looking for. arcgisUtils.createMap(mapid, "map").then(function(response){ var legendLayers = ...


0

This might be a network firewall issue. If two machines are on the same network, with separate public IP address, and the proxy on one machine makes an outbound call to the second machine's public IP, the firewall may flag that as inappropriate traffic, and block it. Talk with the system administrator for the network and see if they make an exception to the ...


0

Actually, I fixed it later today. It is a CSS bug, and here is how I patched it for now: attInspector.deleteBtn.domNode.classList.remove("atiButton"); The problem is that in the the CSS class atiButton has a fixed 16px size (geared towards the navigation buttons) and the delete button should not inherit from it, or better yet, the class should change and a ...


1

This API link from EPA shows the Watersheds http://watersgeo.epa.gov/arcgis/rest/services/NHDPlus_NP21/WBD_NP21_Simplified/MapServer?f=jsapi - raw ...


1

Your query is working fine. The error stack trace you've submitted is pointing to the part of your showResults function where the map's graphics layer is told to clear. The this is usually thrown because the map's graphics layer hasn't loaded, which is probably because the map hasn't finished loading yet. Where you have: query.where = "OBJECTID = 1"; ...


1

It looks like you found the service to use ... http://watersgeo.epa.gov/arcgis/rest/services/NHDPlus_NP21/WBD_NP21_Simplified/MapServer/ Just plug that in to one of the many samples available and start from there. Go Here and click "Browse Samples" https://developers.arcgis.com/javascript/ Find one that does something similar to what you want to do (or ...


0

I don't work with APIs am not exactly sure what you are looking for, but watershed boundary data is available and downloadable as polygon shapefiles from multiple websites. For example, ftp://ftp.ftw.nrcs.usda.gov/wbd/ allows one to download maps at different watershed (HUC) scales. When you say "watershed boundary" you also need to specify at what ...


0

IdentityManager.findServerInfo expects a string, which needs to include a protocol, domain and subdomain. You don't need to include the path to a specific resource. Here's an example using the Identity Manager sample, run this in the console: esri.id.findServerInfo("https://servicesbeta.esri.com"); Path doesn't matter, so this: ...


1

What you can do, is to check the expected Visibility at a particular zoomlevel, and change the layer's VisibleLayers appropriately. The map's zoom-end even is one place where you could check it. Assume that I have a DynamicMapService with 5 Layers in it. I'll define the layervisiblity with something like this: var layerVisibilityInfo=[ {id:0, ...


1

in general, you only get access to the symbology/opacity defined in the service itself. that being said, dynamic layers capability added at 10.1 provides an opportunity to define an entirely new renderer on the clientside for ArcGISDynamicMapServices... Here's a link to the ArcGIS Server help for configuring map services with dynamic layer support: ...



Top 50 recent answers are included