|
POST
|
Yes I have. That explains it! You'd think I would have noticed that behavior in my other code, but I'm still in the process of getting services going and rewriting some of my older code. That's rather a glaring problem, I'm sure to get complaints from the users. It's worked in many other past versions!!!!
... View more
06-26-2014
08:39 AM
|
0
|
0
|
1184
|
|
POST
|
I am using an infoTemplate to show attributes and have it defined in the map definition with an infoWindow as a popup so that each has the small ZoomTo link at the bottom. I'm not sure what is going on behind the scenes with the ZoomTo, but that has always worked just fine for me, with either points, lines or polygons. var popup = new Popup({ fillSymbol: highlightFillSymbol }, domConstruct.create("div")); map = new Map("mapDiv", { infoWindow: popup, basemap: "streets", center: [-92.593, 38.5], zoom: 7 }); infoTemplate = new InfoTemplate(); infoTemplate.setTitle("<b>${NAME}</b>"); This particular project uses ZIP boundaries, which are more complex than some polygons and for whatever reason, which I click the Zoom To, instead of zooming to the polygon, the map is just blank. My layer is set wkid 102100, the same as my basemap. I don't know if it is zooming in past some scale threshold for this particular layer. I'm not sure why it would be doing that. It doesn't show either my layers or the ESRI basemap. I have used this exact same settings for county boundaries and it works just fine. There's nothing in my code that is doing the ZoomTo, just the built in functionality with having a popup as part of your infoWindow definition. I don't have any minimum zoom thresholds set on my service.
... View more
06-26-2014
07:23 AM
|
0
|
3
|
1550
|
|
POST
|
That sounds like quite a hack. That makes me think about my configuration, though. I remember reading somewhere that I should now be adding async:true to my dojoConfig definition. I thought that was the default, but lately I heard the default was actually async:false.
... View more
06-25-2014
11:43 AM
|
0
|
0
|
1660
|
|
POST
|
I have a map that works for most users in Firefox, IE and Chrome. I have reports from a handful of users they can't properly open this map in Firefox, even when we have the same version of Firefox, in this case version 30. I believe it has to do with something in their Firefox browser, maybe a setting or permission, that is different than mine. The majority of people who have tried it all report it opens just fine. We've tried comparing our configurations, but haven't spotted anything yet that is different between computers. They receive an error ReferenceError: require not defined. https://ogi.oa.mo.gov/MDA/ControlPoints/index.html I have been told that I must use https for all maps, even though we only occasionally have something with any secure data. I don't know if that is part of the problem or not. I don't think this is something I can fix in the code. I'm baffled what to tell these users, besides "use something besides Firefox". It's worked fine on my computer through more than one upgrade to my Firefox browser. Is there some thing we could look at in terms of Firefox settings that might help?
... View more
06-25-2014
10:42 AM
|
0
|
4
|
2388
|
|
POST
|
The code I lifted this from knew what NCDM is, I just neglected to get it defined for this thread. All the styling I got from another thread I posted a while back. For that problem, it seemed like I needed it all, so I just copied it into this project. I had been adding more and more to it, when I should have been taking things out. Live and learn.
... View more
06-24-2014
01:31 PM
|
0
|
0
|
860
|
|
POST
|
I have a floating pane containing a dGrid/OnDemandGrid that opens when the user clicks the 'Data Table' button. I'm having problem using the functionality where you can click the header name and have the data sort on that field. I know there is a lot of styling involved in getting the grids to be just right, but I'm not seeing what I need to fix. Maybe something with the dgrid scroller? I also have that nested scrollbar look I don't mean to have. As soon as I resize my floating pane, both the extra scrollbar and my headers start looking and behaving the way I expect, allowing me to click on the headers to sort the data in that column. I know I have a style problem, but someone spot what I need to change? It doubt all my code will fit in the thread, but here's my CSS, followed by my jsFiddle link. #gridContainer{ height: 90%; } .dgrid { position: relative; overflow: auto; /* This is needed by IE to prevent crazy scrollbar flashing */ border: 1px solid #dddddd; display: block; color:black; } .dgrid-grid { height: auto; min-height:350px; } .dgrid-header { font-weight: normal; font-size:12px; height: auto; } .dgrid-content { position: relative; margin-top: 20px; font-size:12px; width:inherit; } .dgrid .dgrid-cell { min-width: 50px; border-color: #dddddd; mid-height: 50px; padding:5px 0px 5px 0px; } .dgrid .dgrid-scroller { max-height: 300px; position: relative; } .dgrid .field-OBJECTID, .field-Shape.len { min-width: 0px; } http://jsfiddle.net/schlot/xk8k8/
... View more
06-23-2014
12:45 PM
|
0
|
2
|
1294
|
|
POST
|
Rene, you're right about trying aspect and Ken you're right that it wanted 'hide' and not 'onHide'. It's working! I've updated my jsFiddle. That may turn out to be a good generic solution for me. As the requests for 'can you make it do this' grow larger, I always struggle to find a place to put everything.
... View more
06-23-2014
06:40 AM
|
0
|
0
|
2125
|
|
POST
|
That's what I'm attempting with this, but my console.log never comes up, so I assume its not the right syntax.
registry.byId('floater_chart').on('hide', function () {
console.log ("floater chart is hidden");
});
I'm getting confused because most AMD has syntax like close, click, hide etc, not onClose, onClick, onHide. I never have much luck digging through the dojo API reference and the documentation is pretty sparse.
... View more
06-20-2014
01:22 PM
|
0
|
0
|
2125
|
|
POST
|
The function for opening the floating pane now includes a pause for the identify click handler and turns on the handler for the 'make chart' click event. When I close the floating pane, I don't know what event I'm listening for, so I can't do the reverse: turn on the identify and turn off the chart making.
... View more
06-20-2014
12:57 PM
|
0
|
0
|
2125
|
|
POST
|
I don't know if you can or not. It's the common mechanism used when you're trying to align data the way you're describing. It's been quite a while since I did anything with customTextElements. Once I had mine set up, I haven't needed to get back into it again. What if you rethought how you're using your added text elements in your layout? If you need to have the data aligned, could you not manage that somehow by having your custom elements aligned the way you want to start? You'd have to play with it a bit to see if you could get away with that as a workaround or not. I'm not sure why sort of behavior you'd get with your longer text string. But you're trying to do something very specific with a limited set of tools at your disposal.
... View more
06-20-2014
06:40 AM
|
2
|
2
|
3291
|
|
POST
|
Have you tried formatting the string as an HTML table? Typically I would use that when trying to line things up the way you're describing.
... View more
06-19-2014
12:23 PM
|
0
|
0
|
3291
|
|
POST
|
I have a map click to do an identify defined initially. I want to be able to let the user click on my chart button to open a floating pane where I will generate a chart. While the floating pane is open, I want the click event to run my generate chart function for the selected polygon instead of my standard identify. I have multiple years of data for each county I want to show, coming out of multiple layers in my service. The data is gathered through another identify that looks at all layers and formats the data the way the chart needs it. That part is figured out, believe or not. I'm stuck on managing my identify click handlers. I've found several threads that discuss switching between the measure tools and identify, but the solution seems to be having a listener on the measure events. Nothing in those solutions helps me with this situation. I tried setting a variable when I defined the identify click event as identifyHandler = map.on('click', identifyClickHandler); I have a function to open the floating pane as registry.byId('btnChart').on('click', function (){ idFromClick = false; chartClick = true; domConstruct.empty("chartDiv"); openFloatingPane('floater_chart'); makeCountyChartClickHandler = map.on( "click", chartCountyByMapClick); }); How do I get rid of identifyHandler? At what point do I turn it back on again? I'm not sure how what the event is for the floatingPane getting closed. All the examples I found are still based on dojo.connect and dojo.disconnect. I also need to clear out the div that's in my floating pane in preparation to creating a new chart. I'm trying to use domConstruct.empty("chartDiv"); Since my chart div is in my floating pane, it looks like the pane is getting destroyed, not closed, so I'm not sure when to empty it. The other thing that is happening is that the chart works OK the first time, but when I click a 2nd time on the same or different county, it's loading my chart over the top of it self multiple times. I think it's doing it because the identify is firing more than once. I'm sure it's because I haven't straightened out my click events yet, but it does seem wierd. Here's my best attempt to post my example: http://jsfiddle.net/schlot/HPDP7/
... View more
06-19-2014
11:57 AM
|
0
|
7
|
2563
|
|
POST
|
In my final solution, I had all those elements incorporated. The user has the opportunity to enter in a title and subtitle. If they don't, I have default strings based on some variables I declared earlier, like the name of the county. Generally the workflow is that the user has identified a particular feature, and details about it is what they want to appear in a printout. I'm storing several variables from that task initially. If they choose to enter their own title/subtitle, those will be used instead of the variables I've stored. For the custom text, I'm pulling data from multiple attributes and concatenating them into a single string. That's what I'm using to populate the customTextElement that I'd previous defined in my custom print template.
... View more
06-05-2014
05:32 AM
|
0
|
0
|
633
|
|
POST
|
I occasionally have problems with both selecting and querying and I always think it relates to the callback function executing before the selection is really complete. Network connectivity, the type and number of features you're selecting can impact whether the selection happens 'instantly' or not. Points seem to be OK, but when I had a project where I was selecting lines with lots of vertices, there was often a problem. When I have this happen, adding selection-complete listener to your featureLayer and then execute the selection without the callback function takes care of this problem. The syntax changes up a bit. Instead of getting to feature like "results[0]" you have to use "results.features[0]".
myLayer.on('selection-complete', selectFeatureHandler);
myLayer.selectFeatures(query);
function selectFeatureHandler (results) {
var feature = results.features[0];
map.setExtent(feature.geometry.getExtent().expand(1.25));
}
... View more
05-16-2014
07:47 AM
|
0
|
0
|
873
|
|
POST
|
I've never had any luck trying to put everything into my code all at once. Lots of times my individual processes will work just fine and I never do spot what was wrong in my original code.
... View more
05-15-2014
08:51 AM
|
0
|
0
|
1831
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 06-02-2017 02:38 PM | |
| 2 | 03-18-2022 10:14 AM | |
| 2 | 02-18-2016 06:28 AM | |
| 1 | 03-18-2024 07:29 AM | |
| 4 | 08-02-2023 06:08 AM |
| Online Status |
Offline
|
| Date Last Visited |
02-25-2025
01:56 PM
|