|
POST
|
Here is my complete code:
function mapClickHandler(evt) {
//build query
var queryTask = new esri.tasks.QueryTask("http://192.168.7.114/arcgis/rest/services/FiberNet/Base/MapServer/0");
var incidents = new esri.tasks.FeatureSet();
incidents.features = [new esri.Graphic(new esri.geometry.Point(evt.mapPoint.x, evt.mapPoint.y, map.spatialReference))];
//build query filter
var query = new esri.tasks.Query();
query.where = "1=1";
query.returnGeometry = true;
query.outFields = ["*"];
queryTask.execute(query, function (queryResult) {
var facilities = new esri.tasks.FeatureSet();
facilities.features.push(new esri.Graphic(new esri.geometry.Point(-13625960, 4549921, map.spatialReference)));
//facilities.features = queryResult.features;
var params = new esri.tasks.ClosestFacilityParameters();
params.defaultCutoff = 3.0;
params.returnIncidents = false;
params.returnRoutes = true;
params.returnDirections = true;
params.facilities = facilities;
params.outSpatialReference = map.spatialReference;
params.incidents = incidents;
//solve
closestFacilityTask.solve(params, function (solveResult) {
var directions = solveResult.directions;
dojo.forEach(solveResult.routes, function (route, index) {
//build an array of route info
var attr = dojo.map(solveResult.directions[index].features, function (feature) {
return feature.attributes.text;
});
routeGraphicLayer.add(route);
dojo.byId("directionsDiv").innerHTML = "Hover over the route to view directions";
});
});
});
} It works when I use: facilities.features.push(new esri.Graphic(new esri.geometry.Point(-13625960, 4549921, map.spatialReference))); It breaks when I use: facilities.features = queryResult.features; I'm not getting an error... the task never even fires off in fiddler. I've tried looping through and adding them to the array manually it still never fires
... View more
05-21-2013
07:47 AM
|
0
|
0
|
609
|
|
POST
|
I recently installed ArcSDE in AcrGIS Server 10.0. I added a feature class to my MXD just fine. When I went to publish I get the following error when I try to enable "Feature Access" otherwise it works fine. Configuration CDA/Sites.MapServer can not be started. Server Object instance creation failed on machine <name>. No Layer or Table was initialized. From the server logs: <Msg time='2013-05-09T15:00:02' type='WARNING' code='10801' target='CDA/Sites.MapServer' methodName='MapServer.Connect' machine='' process='5672' thread='7304'>The Layer:'Sites' in Map:'Layers' is invalid. Bad login user</Msg> <Msg time='2013-05-09T15:00:02' type='ERROR' code='17000' target='CDA/Sites.MapServer' methodName='GraphicFeatureServer.Construct' machine=<name>process='5672' thread='7304'>Initialization failed.</Msg> <Msg time='2013-05-09T15:00:02' type='ERROR' code='1016' target='CDA/Sites.MapServer' machine=<name> thread='2864' elapsed='1.21900'>Server Object instance creation failed on machine <name>. No Layer or Table was initialized. </Msg> <Msg time='2013-05-09T15:00:02' type='ERROR' code='1008' target='CDA/Sites.MapServer' thread='7728'>Configuration CDA/Sites.MapServer can not be started.</Msg> Bad Login User makes me think I have a permissions issue. Does anyone know what I'm doing wrong? Do I have to give ArcGIS Server access to something post-install? Thanks in Advance!
... View more
05-09-2013
01:05 PM
|
0
|
2
|
3186
|
|
POST
|
I'm new to this but my ClosestFacilityTask isn't working. I can't find a working example online so I'm not sure what I'm doing wrong. I don't get an error but it isn't firing off in Fiddler either. Any help? Thanks in Advance.
dojo.connect(gsvc, "onBufferComplete", function (geometries) {
var facilities = new esri.tasks.FeatureSet();
facilities.features = [new esri.Graphic(geometries[0])]; ;
var params = new esri.tasks.ClosestFacilityParameters();
params.facilities = facilities;
params.outSpatialReference = map.spatialReference;
var closestFacilityTask = new esri.tasks.ClosestFacilityTask("http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/Network/USA/NAServer/Closest Facility")
closestFacilityTask.solve(params, function (solveResult) {
alert('success');
});
});
... View more
05-08-2013
03:23 PM
|
0
|
4
|
1271
|
|
POST
|
Looks like I should have been doing a post, not a get. Downloaded Postman for Chrome and it works in that. Thanks,
... View more
11-16-2012
12:49 PM
|
0
|
0
|
656
|
|
POST
|
Thanks for your response. That page looks like this: Security Configuration Protocol: HTTP Only Security for virtual directories enabled: false Authentication tier: GIS_SERVER Authentication mode: ARCGIS_TOKEN User Store Configuration Type: BUILTIN Role Store Configuration Type: BUILTIN
... View more
11-16-2012
09:00 AM
|
0
|
0
|
656
|
|
POST
|
I'm new to ArcGIS server. I'm trying to call the generate token command in .NET, but it keeps giving me this response: {"ssl":{"supportsSSL":false}} Here is the URL I am using: [ip:6080]/arcgis/admin/generateToken?Referer=[ip:6080]&username=[username]&&RequireSSL=False&f=json&password=[password] Is it something in my settings? I don't have an SSL certificate. Thank you in advance.
... View more
11-16-2012
06:27 AM
|
0
|
3
|
2600
|
|
POST
|
I started with the JavaScript API originally. I had no problem with it, well documented and easy to learn. Mostly just worked in Notepad++ and Firebug. A little later when the Flex API came out everyone started asking for it, so I started using that. Again I thought it was pretty easy to learn. It wasn't until the iPad came out that I had to go back to JavaScript. No one was trying to use a huge viewer on their phone, but the table makes it more practical. At the moment I split 50/50 between JavaScript and Flex. I have no problem going back and forth, and I will say the Viewer for Flex makes rapid application development a breeze. I am also less worried about cross testing in different browsers (but differences do come up from time to time). That being said when a client gives me the choice I use the JavaScript API, it's just the way the industry is going and the skills you develop will help if you ever want to work with more JavaScript libraries (jQuery, Dojo, Leaflet, Google, Openlayer, etc).
... View more
07-26-2012
11:46 AM
|
0
|
0
|
656
|
|
POST
|
You can also use the LayerDetails class. See: http://resources.arcgis.com/en/help/flex-api/apiref/com/esri/ags/layers/supportClasses/LayerDetails.html Is this only available if I bring it in as a feature layer? If I do it as dynamic or tiled I can't get to it right? All I see is layerInfos which only contains the name of the sublayer but no definition.
... View more
07-17-2012
02:56 PM
|
0
|
0
|
493
|
|
POST
|
I'm trying to display meta data on sub layers. My plan was to pull it through the API from the Description field. For example "CRS 35-1-105(c) I �?? IV" in the below service: http://165.127.200.27/OITGISDevelopment/rest/services/GovRegions/GovRegions_CDA/MapServer/1 I'm looking for it in the API and don't see it anywhere. Is there a way to get it from the layerInfos object under the ArcGISTiledMapService object? Thanks in advance!
... View more
07-17-2012
01:16 PM
|
0
|
4
|
864
|
|
POST
|
I have an application that I recently updated for a client. They are still seeing the old application in their browser even though they have cleared their cache several times. I found someone else in my office with this problem and having them reload the index.swf fixed the issue but not for my client. Any ideas why this is happening? Has anyone else experienced this? Same URL for me and the client but we are seeing different things. Thank you in advance. -j
... View more
02-21-2011
06:46 AM
|
0
|
1
|
1247
|
|
POST
|
I found the line of code that causes this error. MapManager.mxml line 759: changeNavigation(navigationTool, navigationStatus); Commenting this out seems to remove the error but I am curious if it will break some other functionality at some point. Has anyone else had any experience with this? I have been finding this new API/viewer to be very buggy. -Jordan
... View more
10-28-2010
01:52 PM
|
0
|
0
|
350
|
|
POST
|
I actually noticed a problem which I posted in another thread while using this tool. Has anyone had an issue with the framework jumping around after going to full extent then using this identify tool. It is an issue with the framework because I have the same issue with the draw point in the draw tool. http://forums.arcgis.com/threads/16109-Error-with-Full-extent-on-Sample-Viewer-2 Thanks in advance.
... View more
10-28-2010
09:56 AM
|
0
|
0
|
977
|
|
POST
|
When I use the old of the box configured flex viewer. After I click the full extent button any draw point causes the application to zoom out to the full extent again. Process to reproduce error: 1. Open the default flex viewer (http://help.arcgis.com/en/webapps/flexviewer/live/index.html) 2. Click the full extent button 3. Manually zoom in a little 4. Draw a point (open draw tool) 5. Watch as you get zoomed out to the full extent Has anyone noticed this or come up with a fix? Is it a code change or a problem with the API? I noticed it when trying to use an identify tool so it is with any draw point not just the draw tool Thanks, Jordan
... View more
10-28-2010
09:21 AM
|
0
|
3
|
2253
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 02-12-2014 05:32 AM | |
| 1 | 09-30-2015 11:41 AM | |
| 1 | 05-12-2010 08:17 AM | |
| 1 | 05-12-2010 09:10 AM |
| Online Status |
Offline
|
| Date Last Visited |
11-11-2020
02:23 AM
|