|
POST
|
@Diana- Do you have a screenshot of what that looks like that you could share? I'm in the same boat and the code provided earlier in this thread didn't work well for me and my own kludgy code to "sense" where my feature is on the map and adjust accordingly is almost more trouble than it's worth. I did submit an enhancement idea for ESRI to add an option to map creation so that the API takes care of all this. It's ESRI's code and they know it better than any one of us. Vote if you're so inclined.
... View more
02-07-2013
09:45 AM
|
0
|
0
|
1720
|
|
POST
|
Welcome to the hell that is Internet Explorer. You can look forward to more of this kind of maddening behavior if you ever try using the charting capabilities of dojo. To your follow up question, you can try reading this: Specifying legacy document modes
... View more
02-07-2013
07:37 AM
|
0
|
0
|
731
|
|
POST
|
I can't explain WHY this happens but Jeff's question about window.setInterval() to refresh my page every 5 minutes appears to be on the money. What I ended up doing was calling my update function immediately before specifying the window.setInterval() command and now the features display immediately like they did under v2.8 of the API. One frustrating gremlin down, several more to go. Thanks again to everyone and especially Jeff! Cheers- Steve
... View more
02-05-2013
09:26 AM
|
0
|
0
|
545
|
|
POST
|
Yeah, I noticed that it happens to any of these NWS mapImage overlays. I just wish I knew how to correct it!
... View more
02-05-2013
07:15 AM
|
0
|
0
|
2277
|
|
POST
|
Ok, for comparison, here's a version of our app using v2.8 of the API: http://gismaps.snoco.org/fws28/ This loads quickly and my data (the square symbology) shows up immediately. It's the same code base with respect to the page's 5 minute refresh and the dojo charting, just modifed as required to get running under v3.3.
... View more
02-04-2013
12:15 PM
|
0
|
0
|
545
|
|
POST
|
If you can get the featureSet of your layer, you could sort the featureSet since it really just is an array: var _sort = function(field) { return function(a, b) { var x, y; x = a.attributes[field]; y = b.attributes[field]; return (x < y) ? -1 : 1; }; }; theFeatureSet.sort(_sort('Your Field Name')); Another way of sorting the featureSet would be: theFeatureSet.sort(function(a,b) { return a.attributes.fieldName - b.attributes.fieldName; }); Both of my examples would be for a numeric field.
... View more
02-04-2013
11:17 AM
|
0
|
0
|
2320
|
|
POST
|
I can tell you that neither of these things were issues with this under v2.8 of the API. I'll try to produce a version using the 2.8 API for comparison.
... View more
02-04-2013
08:12 AM
|
0
|
0
|
2131
|
|
POST
|
Here is the live link for the "drifting" overlay I was previously describing: http://gismaps.snoco.org/fws/ Load the page. Under the "Show Me' dropdown, click the checkbox for Radar Image. Now zoom out one level. Note where the radar returns are. Zoom out again one level. Watch the radar returns drift back eastward. Zoom out one more level. This represents the true spatial position of the overlay.
... View more
02-04-2013
07:45 AM
|
0
|
0
|
2277
|
|
POST
|
Ok, we finally have a live version of our app for you to see the lag that I've been describing: http://gismaps.snoco.org/fws/
... View more
02-04-2013
07:39 AM
|
0
|
0
|
2131
|
|
POST
|
Thanks, Derek. That did the trick and now the image displays. I feel somewhat special having stumbled across a bug 🙂 One issue I'm having as I try and incorporate this back into a more complex app I'm developing. From a certain LOD out, the image is displayed in its correct location. From that certain LOD inward, however, the image begins to shift westward and continues to shift further westward with each successive zoom in. If I reverse course and zoom back out, the image will get closer and closer back to where it is supposed to be. I hope to have a live public version I can link to within 2 weeks but for now here are a couple screenshots which show the problem. "ZoomLevel01" shows the mapImageLayer in its correct spatial location. After I zoom my map in one level, I get "zoomLevel02." As you can see, the image has now shifted westward. I'm stumped as to what may cause this because my app uses the same basemap and initial extent as what I originally posted in the simple example (and what's used in your fiddle). Thoughts, guesses? [ATTACH=CONFIG]21217[/ATTACH][ATTACH=CONFIG]21218[/ATTACH]
... View more
01-30-2013
08:19 AM
|
0
|
0
|
2277
|
|
POST
|
I want to add some weather service radar overlays to my app. Originally, I was hoping to add them via a KML/KMZ as provided by this NWS site. After reading the API documentation about KMLLayers, i concluded that this type of KML layer might not be supported (image overlay). That led me to the MapImage layer and I'm having no luck getting the image to display. While investigating the guts of the NWS KML file, I see that it's simply a georeferenced GIF file: [ATTACH=CONFIG]21185[/ATTACH] I noted the lat/long extents, along with the image dimensions and have tried implementing a simple example with no success. So what am I missing?? THANKS! Steve Code: <!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"> <!--The viewport meta tag is used to improve the presentation and behavior of the samples on iOS devices--> <meta name="viewport" content="initial-scale=1, maximum-scale=1,user-scalable=no"> <title>Map Image Test</title> <link rel="stylesheet" href="http://serverapi.arcgisonline.com/jsapi/arcgis/3.3/js/dojo/dijit/themes/claro/claro.css"> <link rel="stylesheet" href="http://serverapi.arcgisonline.com/jsapi/arcgis/3.3/js/esri/css/esri.css"> <style> html, body, #map { padding:0; margin:0; height:100%; } </style> <script>var dojoConfig = {parseOnLoad: true};</script> <script src="http://serverapi.arcgisonline.com/jsapi/arcgis/3.3/"></script> <script> dojo.require("esri.map"); dojo.require("esri.layers.MapImageLayer"); var map; dojo.ready(function() { var initExtent = new esri.geometry.Extent({ "xmin": -13592500, "ymin": 6060280, "xmax": -13506825, "ymax": 6166129, "spatialReference": {"wkid": 3857} }); map = new esri.Map("map", { basemap: "streets", extent:initExtent }); // Define the NWS Radar Layer var radarMi = new esri.layers.MapImage({ 'extent': { 'xmin': -125.725156, 'ymin': 45.222770, 'xmax': -119.252062, 'ymax': 51.156440, 'spatialReference': { 'wkid': 4326 }}, 'href': "http://radar.weather.gov/ridge/RadarImg/N0R/ATX_N0R_0.gif" }); radarMi.height = 550; radarMi.width = 600; radarMi.scale = 1; var nwsRadarLayer = new esri.layers.MapImageLayer(); nwsRadarLayer.addImage(radarMi); map.addLayer(nwsRadarLayer); }); </script> </head> <body class="claro"> <div id="map"></div> </body> </html>
... View more
01-29-2013
02:01 PM
|
0
|
5
|
2916
|
|
POST
|
Hi Ken, No- this lag occurs at the initial page load. I can still pan/zoom and interact with my other layers; it's just that this one featureLayer won't appear for 4 minutes. After it finally does appear, everything functions normally.
... View more
01-29-2013
12:26 PM
|
0
|
0
|
2131
|
|
POST
|
As an update, my own stripped down test app does not exhibit the lag time behavior I originally described. Looks like I'll need to provide a link to the actual app. I'll do so ASAP, but that probably will be in 2 weeks.
... View more
01-29-2013
09:38 AM
|
0
|
0
|
2131
|
|
POST
|
Hi Kelly, Thanks for replying. I'm hoping to be able to provide a link to the live app within about 2 weeks once we upgrade our production server to 10.1. Regarding your question..I don't know. I've tried some of the ESRI samples that use JSONP and they all seem responsive. I'll have to see if I can create one on my end. I may have something that could fit your description but I'll need to combine bits of code to get a final test. If not, I'll update this thread with the link to my live version once we upgrade our server.
... View more
01-29-2013
08:10 AM
|
0
|
0
|
2131
|
|
POST
|
I've been developing under the 2.8 API and my app has loaded immediately but, under the 3.3 API, it's exhibiting a weird lag time. One of my featureLayers is constructed on the fly using a FeatureCollection. Using some well placed console.log commands, I can see that the code is, in fact, running immediately (including processing the deferred results which are used to construct the featureCollection). The problem is that those features are NOT visible or clickable for another 4 minutes! After that 4 minutes, the features suddenly appear and everything is fine. There's no error to speak of in the console and, again, it runs fine in v2.8 We're using ArcGIS Server 10.1. This app is currently running on an internal, developmental server but I'm hoping to push a public version soon (I have some other issues I need help with). Has anyone else experienced weirdness like this with the 3.3 API? Steve
... View more
01-25-2013
09:50 AM
|
0
|
12
|
3237
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 03-12-2026 01:43 PM | |
| 1 | 03-12-2026 08:41 AM | |
| 2 | 03-10-2026 10:10 AM | |
| 1 | 02-18-2026 09:20 AM | |
| 3 | 01-22-2026 02:03 PM |