POST
|
Hello, I want to make a findTask that gives me all the features with this searchText: findParams.searchText = " "; The problem is the map service is limited to 500 features per findTask, is there any way of asking the server for the information in another way or creating a loop that is able to ask for the features sequentially? Sadly I am not able to edit the map service so I can't change the limit of the answers that the findTask is sending me. Thanks in advance PD: here you can find the code that retrieves the data
findTask = new esri.tasks.FindTask("https://maps.cern.ch/ArcGIS/rest/services/General/loc/MapServer/");
findParams = new esri.tasks.FindParameters();
findParams.returnGeometry = true;
findParams.layerIds = [6,7,8,10,11,15,16,17,19];
findParams.searchFields = ["NUMERO", "SIGLE", "SITE","TITLE","SPAT_NAME","SPAT_ACCL_NAME","LOCATION_EXPERT_NAME"];
findParams.outSpatialReference = map.spatialReference;
findParams.searchText = " ";
findTask.execute(findParams,function (results) {
//parse results and add to autocomplete widget
dojo.forEach(results, function(value, index){
names.push(value.value);
});
}, function (error) {
alert("Error: " + error);
});
... View more
04-08-2013
02:02 AM
|
0
|
1
|
590
|
POST
|
Yes I have some custom css, I will check if there are some incompatibilities
... View more
11-29-2012
10:37 PM
|
0
|
0
|
185
|
POST
|
Hello, I created an little infoWindow for some features in my map, so it will popUp when clicking on it. The problem is that the window is not shown like a normal window, it has a little gap in between: [ATTACH=CONFIG]19604[/ATTACH] Here is my code where I attach the infoTemplate to the features: var infoTemplate = new esri.InfoTemplate();
infoTemplate.setTitle("${NAME}");
infoTemplate.setContent("<b>Name </b>${SPAT_NAME}<br/>"
+ "<b>Dose: </b>"+colorSquema[feature.attributes["SPAT_NAME"]]+"<br/>");
feature.setInfoTemplate(infoTemplate);
map.graphics.add(feature); I am getting the features from a query to the map. Any idea? Thank you so much
... View more
11-29-2012
06:11 AM
|
0
|
2
|
633
|
POST
|
Ok, this looks like what I want, now I need to find a way of iterating through the fields, this should be easy. Thank you so much
... View more
11-12-2012
11:30 PM
|
0
|
0
|
242
|
POST
|
Hello, I want to create a map that is similar to this, but instead of retrieving the information from a static FeatureLayer I want to create one with the data obtained in a findTask. So depending on the find task the colored areas should change. This is the code I have: function do_search(e){
if (e.keyCode == 13) // 13 = enter key
{
findParams.searchText = dojo.byId('search').value;
findTask.execute(findParams,zoomInSearch);
}
}
function zoomInSearch(results){
//This function works with an array of FindResult that the task returns
map.graphics.clear();
var items = dojo.map(results,function(result){
var graphic = result.feature;
//graphic.setSymbol(symbol);
map.graphics.add(graphic);
return result.feature.attributes;
});
//Create data object to be used in store
var data = {
identifier: "OBJECTID", //This field needs to have unique values
label: "OBJECTID", //Name field for display. Not pertinent to a grid but may be used elsewhere.
items: items
};
//Create data store and bind to grid.
store = new dojo.data.ItemFileReadStore({ data:data });
// I want to use this data to creae a Feature layer so it can be shown in the map, somehow Or could I create a dataSource from the findTask, so I could create something similar to this example Any idea? Many thanks
... View more
11-09-2012
03:22 AM
|
0
|
3
|
1868
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:24 AM
|