|
POST
|
It could be the way our dns names are resolved. I haven't had any other connectivity issues.
... View more
02-20-2015
10:49 AM
|
0
|
2
|
761
|
|
POST
|
Thanks for trying. It's probably something about the way my computer is set up. At least I'm admin on my machine!
... View more
02-20-2015
09:22 AM
|
0
|
0
|
761
|
|
POST
|
I just got those browsers version of the same error statement.
... View more
02-20-2015
09:09 AM
|
0
|
2
|
1692
|
|
POST
|
I removed the extracted folder and went back to the original ZIP. This time when I ran startup.bat, instead of just the listening statement, I saw all the insert statements as well. But I'm still getting the error 'web page not found' in the browser window.
... View more
02-20-2015
09:05 AM
|
0
|
1
|
1692
|
|
POST
|
Yes, that's what it looks like in my command window, with only a different folder name. The machine name is rather long and includes the domain http://mymachine.mydomain.state.mo.us:3344/webappbuilder This naming convention is typical for us, there are so many AD accounts they wouldn't all fit in one domain. It doesn't seem like it should be a problem.
... View more
02-20-2015
08:31 AM
|
0
|
0
|
1692
|
|
POST
|
I have, but I am stuck before I encounter any of the issues listed there. When I click startup.bat, it opens the command prompt which I think tells me node.js has installed OK, there are no errors in that window. Then it opens the browser window ( my default is Chrome) and gives the error. I assume I can run this on my local machine, as long as I have IIS set up on it.
... View more
02-20-2015
08:18 AM
|
0
|
2
|
1692
|
|
POST
|
I'm having problems getting started with this. I installed node.js on my machine. I think my IIS is installed correctly. I downloaded the appBuilder into a new folder called AGS_webAppBuilder. When I click on startup.bat, which seems to be the next step, it comes back with "This web page not available".
... View more
02-20-2015
07:56 AM
|
0
|
13
|
6049
|
|
POST
|
I get what you're saying, but I'm not any good with separating things into modules OR how to create my own variation of what ESRI has written. All the examples I've found to get me started makes some assumptions about what background and programming experience you come from (which I don't have). I get lost right away with how to get everything talking to each other.
... View more
01-29-2015
01:15 PM
|
0
|
0
|
1435
|
|
POST
|
Adding a proxy and proxy rule took care of this issue for me. However, changing every map in my production environment just so one new basemap works isn't realistic.
... View more
01-26-2015
12:21 PM
|
0
|
0
|
1820
|
|
POST
|
This is not a new problem, but I have yet to come up with a very satisfactory solution. How do you keep your infoTemplate from getting cut off? My content isn't very complicated. I have used a map.infoWindow.resize to make it a little wider. I have a function to format the contents. map.infoWindow.resize(340,300); I have a listener on the show event of the map.infoWindow. The trick apparently isn't to move your infoTemplate, but instead to move your map if it detects the window is going to get cut off, panning the map enough so the tag isn't cropped. on(map.infoWindow, "show", adjustMapExtent); I got this from an older thread and it seems to be working. function adjustMapExtent(){
var maxPoint = new Point(map.extent.xmax, map.extent.ymax, spatialReference);
var centerPoint = new Point(map.extent.getCenter());
var mapPt = new Point(map.infoWindow.location, spatialReference);
screenPt = map.toScreen(mapPt);
//Convert these to screen coordinates
var maxPointScreen = map.toScreen(maxPoint);
var centerPointScreen = map.toScreen(centerPoint);
//Subtract the size of the infoWindow, including a buffer.
//This will show whether the infoWindow would spill out of the current view.
var xDiff = Math.abs(maxPointScreen.x - screenPt.x) - 350;
var yDiff = Math.abs(maxPointScreen.y - screenPt.y) - 310;
//If required, recalculate a new centerpoint which accounts for the infoWindow
if (xDiff < 0) {
centerPointScreen.x -= xDiff;
}
if ( yDiff < 0) {
centerPointScreen.y += yDiff;
}
//Pan the map to the new centerpoint (in Map coordinates)
centerPoint = map.toMap(centerPointScreen, spatialReference);
map.centerAt(centerPoint);
} Here's my problem/complaint. This works the first time. However, unless you've dismissed the tag, the 'show' listener doesn't get fired again, because there is still an infoWindow displayed. The event doesn't fire for every new infoWindow, just 'when an infoWindow in visible'. This is an important distinction. Is there some other event I could be listening for? I tried adding an event listener on the map click to do a 'map.infoWindow.hide()', but that seems to prevent the info tag from ever displaying.
... View more
01-26-2015
12:10 PM
|
0
|
5
|
5844
|
|
POST
|
I posted a similar issue (national map over https) and got NO responses. I'm mandated to use https for everything and I can't get that basemap to load either. Occasionally I'll run into a site that doesn't support https. That must be the case with the hosting server for that basemap. If anyone knows of a workaround, I'd like to hear it too. Ideally that basemap would be changed to allow https connections.
... View more
01-26-2015
08:44 AM
|
0
|
6
|
1820
|
|
POST
|
I am required to use https for all my calls. Occasionally I'll run into content that I can't use through https. This seems to be the case for the new basemap in the basemap gallery basemap.nationalmap.gov. Is there any workaround for this? I'm using the basemap widget, so it loads whatever is currently available.
... View more
01-21-2015
10:36 AM
|
0
|
0
|
4206
|
|
POST
|
OK, I got it working. Now I need to take it further. I need to step through all circles and build a composite list of all nearby features. The output needs to include both some of the attributes of the the input (objectid, name) followed by all the features in the comparison layer that are within it's buffer. What I came up with seems right, but since I have multiple features now, not one,it seems like it needs to be changed to something with a deferred. It doesn't seem to execute in the right sequence. Here's the sequence: Select a county name from a pick list. Use that name to run a query task against the input layer. The result is selected points //zooms to county selected in the dropdown list function zoomCounty () {
findTask = new FindTask((countyLayer.url));
findParams = new FindParameters();
findParams.returnGeometry = true;
findParams.layerIds = [0];
findParams.searchFields = ["COUNTYNAME"]; //Fields are CASE SENSITIVE
findParams.outSpatialReference = spatialReference;
var countyName = registry.byId("countySelect").value;//Set the search text to the value selected in the list
// var countyName = "Boone";
currentCounty = countyName;
if (countyName.length > 1){
findParams.searchText = countyName;
/*
findTask.execute(findParams, function (results) {
map.setExtent(results[0].feature.geometry.getExtent().expand(1.5));
});
*/
updateLcarsGrid();
}else{
console.log('no county selected');
}
} These are placed into a formatted grid //Populates a list of LCARS for that county function updateLcarsGrid(){
var queryParams = new Query();
queryParams.geometry = currentExtent;
queryParams.spatialRelationship = Query.SPATIAL_REL_CONTAINS;
queryParams.outFields = ["*"];
queryParams.outSpatialReference = spatialReference;
queryParams.returnGeometry = true;
queryParams.where = "County = '" + currentCounty + "'";
var queryTask = new QueryTask(lcarsLayer.url);
queryTask.on ('error', queryErrorHandler);
queryTask.execute(queryParams, updateLGridHandler);
}
function queryErrorHandler(err) {
console.log ("error in queryTask is " + err.error);
}
function updateLGridHandler(results){
domClass.remove("dataDiv", "dataDivBlank");
domClass.add("dataDiv", "dataDivOpen");
// dom.byId("messages").innerHTML = "";
var data = [];
if (lgrid) {
lgrid.refresh();
}
if (results.features.length > 0) {
data = arrayUtils.map(results.features, function(feature){
return {
'id': feature.attributes.OBJECTID,
'facility_type': feature.attributes.Facility_Type,
'regulatory_type': feature.attributes.Regulatory_Type,
'facility': feature.attributes.Provider_Name,
'address': feature.attributes.Address,
'city': feature.attributes.City
};
});
lgrid = new Grid({
renderRow: renderRowFunction,
showHeader: false
}, "lcarsGridDiv");
lgrid.renderArray(data);
lgrid.sort('facility');
lgrid.on('.dgrid-row:click', function(evt){
gridClick = true;
var row = lgrid.row(evt);
var rowid = [row.data.id];
gridAddr = row.data.address;
gridClickHandler(rowid);
});
generateBufferGraphic(results.features);
var compArray = selectAllInBuffer();
console.log("end of selectAllInBuffer");
}else {
var countyName = registry.byId("countySelect").value;//Set the search text to the value selected in the list
// var countyName = "Boone";
if (countyName.length > 1) {
findParams.searchText = countyName;
findTask.execute(findParams, function(results){
map.setExtent(results[0].feature.geometry.getExtent().expand(1.5));
});
alert("No LCARS in this county. Select another from the list.");
}
}
} There is a pick list of distances. This is input for generating circle buffers, which go into a graphicsLayer. //create a buffer graphic for every LCARS
function generateBufferGraphic(features){
bufferLayer.clear();
var radius = registry.byId("bufferSelect").value;
var idPoint,circle;
compareSel.length = 0;
//added ts 12/30
var query = new Query();
query.returnGeometry = true;
arrayUtils.forEach(features, function (feature){
idPoint = feature.geometry;
circle = new Circle({
center: idPoint,
geodesic: true,
radius: radius,
radiusUnit: "esriMiles"
});
var graphic = new Graphic(circle, bufferSymbol,feature.attributes);
graphic.attributes.Source = 'LCARS';
bufferLayer.add(graphic);
});
//Added "if" so the zoom wouldn't happen if the buffer alone changes.
if (justBuffer == false) {
var ext = graphicsUtils.graphicsExtent(bufferLayer.graphics).expand(2);
map.setExtent(ext);
}
justBuffer = false;
} Then these graphics are used one at a time as the geometry for a comparison layer using a selectFeatures. The output from that selection might be zero, or multiple. This seems to be where I'm failing. With breakpoints, I can see there are features within an individual circle. By the time I finish all the looping, I always end up with zero! function selectAllInBuffer(){
lcarsLayer.clearSelection();
compareLayer.clearSelection();
compareSel.length = 0;
// var graphics = bufferLayer.graphics;
compareLayer.on('selection-complete',function (results){
var len = results.features.length;
if (len > 0) {
arrayUtils.forEach(results.features, function(feature){
compareSel.push({"lcars":lcarsProv,"results":feature.attributes});
console.log("compareSel length = " + compareSel.length);
});
}else{
console.log(" no nearby facilities");
}
});
arrayUtils.forEach(bufferLayer.graphics, function (graphic){
query.geometry = graphic.geometry;
graphic_oid = graphic.attributes.OBJECTID;
lcarsProv = graphic.attributes;
compareLayer.selectFeatures(query);
});
return compareSel;
} This is sensitive data, or I'd post a link. I'm hampered by a broken wrist, so I'm not quite up to making a jsfiddle. Hopefully someone will spot something. There are no errors generated from this code, I'm just not getting the results I expect.
... View more
12-31-2014
08:36 AM
|
0
|
0
|
3197
|
|
POST
|
I could only get this to work with the extent of the graphic, not the actual geometry of the circle, which was my original question. I guess the answer is, Circle isn't interpreted as a Polygon in this situation.
... View more
12-12-2014
02:46 PM
|
0
|
3
|
3197
|
|
POST
|
That's what I thought to, but my featureLayer query keeps failing. I put my buffered points into a graphicsLayer (the one you just helped me with the attributes). I need to know if any features in my featureLayer as within a set distance to other features in that same layer. Plus I have a 2nd layer that I need to query as well, which I'll get to next. I figured using a separate graphicLayer would help with this, plus I needed the graphics to display anyway. function selectAllInBuffer(){ primaryLayer.clearSelection();//my featureLayer arrayUtils.forEach(bufferLayer.graphics, function (graphic){//my graphics layer full of circles var query = new Query(); query.geometry = graphic.geometry; primaryLayer.queryFeatures(query, FeatureLayer.SELECTION_ADD, function (result){ console.log('queryResult');//just so I had a place to put a breakpoint }); }); Am I not accessing the graphics of my graphicsLayers correctly? It seems pretty straight forward. Have you ever gotten a clear idea of the different between queryFeatures and selectFeatures? It seems like I read something a while ago, but the explanation was too obscure to make much sense.
... View more
12-12-2014
08:28 AM
|
0
|
5
|
3197
|
| 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
|