POST
|
I put in a string type check for the second parameter of the renderere constructor in the latest check in. That shold take care of the problem.
... View more
09-24-2014
10:38 AM
|
3
|
0
|
819
|
POST
|
http://gis.fema.gov/REST/services/FEMA/Surge/MapServer That site has a custom installation, no "arcgis" application and SOAP end point seems deployed separately. If upgrading to 10.01+ is not option, you need play with http://utility.arcgis.com/sharing/tools/legend with that site until you can figure out how to get a legend JSON file. It would helpful if you have access to admin.
... View more
06-16-2014
11:41 AM
|
0
|
0
|
782
|
POST
|
That Fiddle show a new error. However, if you switch back to 3.8, that error goes away. The problem for the code is around the event used to trigger the creation of the digit. The code used 'layer-add-result', which is an event that fired multiple times, thus the developer was actually trying to create many instances of TOC and would running into problems. Even developer code just called 'addLayer' once, the basemap add by API itself would trigger that event internally too. Having something like "if (toc==null ) toc=new ..." might help, although it is really about make sure knowing when the code will be called. Why 3.8 worked could be just how DOJO internally check div changed, may not even an ESRI thing.
... View more
05-08-2014
10:18 AM
|
0
|
0
|
304
|
POST
|
only one layer is visible at any given time. If user clicks a layer to make it visible then the control should automatically uncheck the previous visible layer if any is visible. A new 'toc-node-checked' event is added in the latest version. The event carries information about which root layer, service layer is checked, and whether its on/off, so your requirement can be simply:
toc.on('toc-node-checked', function(evt){
if (evt.checked && evt.rootLayer && evt.serviceLayer){
// this basically tell the service only set the one layer clicked visible. TOC will automatically check off other layers.
evt.rootLayer.setVisibleLayers([evt.serviceLayer.id])
}
}
});
... View more
04-04-2014
11:08 AM
|
0
|
0
|
831
|
POST
|
This is what I did. 1. Created a simple view - create or replace view v_sites as select objectid, site_no, shape from properties; 2. In ArcMAP I brought the view in as a query layer. I am not able to do an identify here on any of the features. I thought I could but I just did a test and I can't. Assuming you are using SDO_GEOMETRY, you should verify the spatial index is been used. The identify operation will send a SDO_FILTER request to Oracle, something like "SELECT SELECT * FROM YOUR_SPATIAL VIEW WHERE SDO_FILTER (SHAPE, SDO_GEOMETRY ('POLYGON ((.....))', YOUR_SRID), 'querytype=window') = 'TRUE';". Review your execution plan, if the spatial index is not been used, you may need to force an index hint in the view definition. We used to have to do that, although seem no longer necessary in newer versions. If you can not do identify in ArcMap, you are not going to get that in later steps. You need to fix it at that stage.
... View more
02-10-2014
11:59 AM
|
0
|
0
|
813
|
POST
|
Hello All, Can we develop arcgis javascipt web application without using DOJO. Please let me know the possibility. Regards, RG If what you actually mean is "develop arcgis web application using Javascript", then you can work directly with REST API. Esri also released a (unsupported) library working with Leaf-let, you can find it on github, no dojo required.
... View more
09-16-2013
05:46 AM
|
0
|
0
|
723
|
POST
|
"Unable to generate legends: zzzzz?Unable to connect to Host: zzzzz Port: -1?Please verify the Service URL specified is correct :- http://zzzzz/arcgis/services/LIVEinternal/aerials/MapServer?" Looks like the error is on REST API side. You might have some data source with inconsistent connection such as timeout easily etc. When server is trying to create legend it may run into a broken link and error out initially. Checking server log via ArcGIS manager may provide some clue. You can also write a small app that make a legend request at given interval and record the results to see if there is a pattern of failing. You can also replace the TOC with esri.dijit.Legend and see if you got error too.
... View more
09-11-2013
03:59 AM
|
0
|
0
|
455
|
POST
|
So if I have a Paved Areas layer, with Road, Parking, and Driveway attributes, I would see three checkboxes under the 'Paved Areas' layer and I could turn off just parking, with an older AGS JS TOC? That was the most powerful and complex feature in the widget. It look thorough the uniquevaluerenderer, breaks up values, create check boxes for each, and based on what user checked, generate a definition query (mainly with "OR" in where clause) and pass to server to display a subset. Unfortunately, there was a bug(NIM074988) in REST API that can not handle passed in definitions correctly if the predefined expression contains an "OR" in where clause without full parenthesis around it. That was the case for the sample map service. It was not fixed for a long time. Esri eventually declined the bug because not producible in latest version, but they also no longer return the predefined query expression in the layer meta data, that also have impact on the code. On top of that, if the application code actually set query definition manually, it became quite difficult to sync what the TOC trying to do and what the application trying to do. With all these issues, that function was dropped. If you do want that, you can use v2.04 before you upgrade your server to a version that no longer returns predefined expression such as 10.2. you had to add a query statement for some reason in the layer, but 1=1 (ie everything) did the trick. A pre-defined definitionExpression (even 1=1) is used in the code as a trigger to generating checkboxs for UniqueValueRenderer's individual value. It was stated in the "build legend node" section of the source code.
... View more
09-06-2013
08:41 AM
|
0
|
0
|
567
|
POST
|
NIM is still open. In REST API, "visible" means default visibility defined in map service, not in the client map instance. The JS API design separated task from Map/service, as a result, the task has no knowledge of which layer is actually visible -- because it does not hold a reference to the map/service instance. Given the circumstance, it is much easier for the application code, which holds reference to both service and task, to passing the actual visible ID list into IdentifyParameter and use IDENITIFY_ALL. To fix the "bug", the identify task class has to accept the map service layer in the constructor, which would be a bit awkward coding neatness wise, and I see no incentive to fix that from Esri perspective, so my advise is that do not count on it, use the alternative and move on.
... View more
09-04-2013
10:53 AM
|
1
|
0
|
1022
|
POST
|
Basically I want my users to be able to switch greyed out layers on, even when they are greyed out This could lead to some confusing behavior, cause the user may expect the layer to be visible after click. You may consider force the map zoom when user clicked something that is out of scale. If you really want to enabled the disabled checkbox for out of scale layers, you can have a function like.
function enableAllCheckBox(){
dojo.query('.agsjsTOCOutOfScale').forEach(function(node, idx){
var tocNode = dijit.getEnclosingWidget(node);
if (tocNode.checkNode) {
if (tocNode.checkNode.set) {
// for dijit.form.CheckBox
tocNode.checkNode.set('disabled', false);
} else {
// for regular HTML checkbox input
tocNode.checkNode.disabled = false;
}
}
});
} Then call this function in the 'onLoad' of TOC, then attach to 'onZoomEnd' event of map. Use a timer if necessary.
... View more
08-12-2013
09:56 AM
|
0
|
0
|
766
|
POST
|
when I copied the GoogleMapsLayer, I misspelled it, thus it could not find it. You are probably not using the latest version. GoogleMapsLayer was used in a fairly old version in which it get special treatment like toggle traffic layers and switch between basemaps within TOC etc. However, all these features were removed to keep the TOC itself simple. The download page on arcgis.com links to http://www.arcgis.com/sharing/rest/content/items/6e816dab9ea243608ef02236c113a8b4/data However your browser cache give you an older version. You may need clean your history or use ctrl+f5 to force it. The unzipped build../TOC.js should have a built date of 2013-08-05 or later at the top, as: /*built on 2013-08-05 12:16:32.99*/
define("agsjs/dijit/TOC",["dojo/_base/declare","dijit/_Widget","dijit/_Templated","dojox/gfx","dojo/fx/Toggler","dijit/form/Slider"],function...
... View more
08-09-2013
08:11 AM
|
0
|
0
|
766
|
POST
|
hI, I am attempting to host the 'agsjs' files on our own server, I downloaded the code from //http://gmaps-utility-gis.googlecode.com/svn/tags/agsjs/ and put it in folders on our server and then use path like: These are "custom modules". Please make sure you have successfully setup at least one simple dojo custom module on your own server first. There are a few samples in the ArcGIS documentation to walk you through. Once you get past that stage, make sure you saved all file from the code hosting site. Ideally you should use a SVN client to check out the code. Alternatively you can download a zip file from the page on arcgis.com download link. If you browser complains can not find a file, chances are you did not save it to correct location, download it and follow Esri or dojo documentation.
... View more
08-08-2013
11:49 AM
|
0
|
0
|
766
|
POST
|
TOC widget to not collapse layer Groups when it is turned off? By default, if a group layer is turned off, or there is no any sub layer visible, it will be collapsed, this is a desirable behavior to minimize vertical scrolling. With the most recent built (as of 8/5) there is a new option 'autoToggle' in the constructor that disables this behavior. http://www.arcgis.com/home/item.html?id=9b6280a6bfb0430f8d1ebc969276b109 Notice when you click "insert a new layer", the new TOC for the census layer has 'autoToggle'=false, and it will not automatically expand/collapsed based on the current visibility of the group/sub layers.
... View more
08-06-2013
02:17 AM
|
0
|
0
|
648
|
POST
|
adding a class to the image ACM I added class 'agsjsTOCIcon' class. It's in code not in template string because feature layer's symbol is replaced by a SVG/VML container, not a IMG. If you just need to set your icon image style, you do not really need this new class, simply use
.agsjsTOCNode img {
/* your style */
} in your style sheet would be sufficient. But I added the class to cover client side none IMG symbol.
... View more
08-05-2013
05:35 AM
|
0
|
0
|
1927
|
POST
|
Is there any way to have the map service layer initially expanded but all collapsible groups within the map service (unique value renderers and group layers) collapsed? Yes, with the latest built posted on http://www.arcgis.com/home/item.html?id=9b6280a6bfb0430f8d1ebc969276b109 it is possible to retrieve individual node widget by it's underline layer. All you need to do is to find the list of layers based on whatever criteria you have, then find it's corresponding node in the TOC, and do something with it (collapse, expand, show, hide), after the TOC is loaded.
... View more
08-05-2013
05:06 AM
|
0
|
0
|
648
|
Title | Kudos | Posted |
---|---|---|
1 | 09-04-2013 10:53 AM | |
33 | 07-19-2012 01:20 PM | |
6 | 07-19-2012 01:22 PM | |
6 | 07-19-2012 01:22 PM | |
1 | 07-26-2013 10:51 AM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|