POST
|
I have designed a time enabled ArcGIS workspace. I have been able to configure the time slider to adapt it to the data, the information provided, the time increment and the country I am working in (Australia). However, when sharing this as a service and publishing as an app, the time slider widget provides no apparent means of duplicating these modifications and insists on using two pointers for start and end dates. Does ESRI have plans to update this widget to be consistent with the design flexibility in ArcGIS and within the JavaScript API?
... View more
06-13-2016
11:02 PM
|
0
|
0
|
1652
|
POST
|
Unofficial Robert I'm using IE10. I'll use your suggested code and am about to see how best to make use of its Developers tool. Richard
... View more
02-23-2016
01:56 PM
|
0
|
0
|
599
|
POST
|
Thanks Robert (again). Valuable advice I'll endeavour to follow. I'm finding that the behaviour of my script in Internet Explorer differs from Chrome. Are there specific requirements for each and, if so, is there a way of ensuring a capability for both?
... View more
02-23-2016
01:43 PM
|
0
|
2
|
599
|
POST
|
Thanks Tyrone My apologies for not supplying more info on the context. The call has the structure: http:<server reference and javascript>?extent=<minx, miny,maxx,maxy>&mapOnly=true. This part seems to work. I've received valuable advice on programming basics, but am also beginning to think that Internet Explorer may also be causing some problems. Using Chrome gives variant results.
... View more
02-23-2016
01:37 PM
|
0
|
0
|
599
|
POST
|
Below is script intended to label the axes of a grid. But first, I need to have the label displayed. The labels are not displaying. Can anyone out there suggest what I may be doing wrong? (My apologies for the repeated requests for help. I'm learning as I go and, until I take a JavaScript course, it will be 2 steps forward and one back). The script takes a set of coordinates in the URL and displays a box. It then displays a feature layer grid with fields containing latitude and longitude values for each grid line. To overcome one problem at a time, I have replaced the field name in the json expression with a constant text value. <!DOCTYPE html> <html> <head> <title>Bounding Box</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"> <link rel="stylesheet" href="https://js.arcgis.com/3.15/dijit/themes/claro/claro.css"> <link rel="stylesheet" href="https://js.arcgis.com/3.15/esri/css/esri.css"> <style> html, body, #mapDiv{padding: 0;margin: 0;height: 100%;} </style> <script src="https://js.arcgis.com/3.15/"></script> <script type="text/javascript" src="dojo/dojo.js" data-dojo-config="parseOnLoad: true"></script> <script> var URLExtent = this.location.href.split("=")[1].split("&")[0].split(","); require(["esri/map","esri/layers/FeatureLayer","esri/geometry/extent","esri/SpatialReference","esri/geometry/Polygon","esri/graphic","esri/symbols/SimpleFillSymbol" ,"esri/symbols/SimpleLineSymbol","esri/Color","esri/layers/GraphicsLayer","esri/dijit/Scalebar", "esri/layers/LabelLayer", "esri/symbols/TextSymbol", "esri/symbols/Font", "esri/layers/LabelClass", "dojo/parser","dojo/on","dojo/domReady!"], function(Map,FeatureLayer,extent,SpatialReference,Polygon,Graphic,SimpleFillSymbol,SimpleLineSymbol,Color, LabelLayer, TextSymbol, Font, LabelClass, parser,Scalebar,on) { var arrayOfCoordinates = [[URLExtent[0],URLExtent[1]],[URLExtent[2],URLExtent[1]],[URLExtent[2],URLExtent[3]],[URLExtent[0],URLExtent[3]],[URLExtent[0],URLExtent[1]]]; var spatialRef = new esri.SpatialReference({wkid:4326}); var startExtent = new esri.geometry.Extent(URLExtent[0],URLExtent[1],URLExtent[2],URLExtent[3]); startExtent.spatialReference = spatialRef; map = new Map("mapDiv", { basemap: "streets", extent: startExtent, showLabels : true }); var box = new esri.geometry.Polygon(arrayOfCoordinates); var sfs = new SimpleFillSymbol(SimpleFillSymbol.STYLE_SOLID, new SimpleLineSymbol(SimpleLineSymbol.STYLE_DASHDOT, new Color([255,0,0]), 2),new Color([255,255,255,0.25]) ); var lsymbol = new TextSymbol(new Color([255,0,0]),new Font("14pt",Font.STYLE_ITALIC,Font.VARIANT_NORMAL, Font.WEIGHT_BOLD,"Arial")); var json = { "labelExpressionInfo": {"value": "longitude"} }; var lc = new LabelClass(json); lc.symbol = lsymbol; var featureLayer = new FeatureLayer("http://services2.arcgis.com/rzk7fNEt0xoEp3cX/arcgis/rest/services/graticule_GDA94/FeatureServer/0",{ id: "grat", //labelingInfo: [lc], showLabels: true, outFields: ["*"] }); map.on("load",function(){ var graphic = new Graphic(box,sfs); map.graphics.add(graphic); map.setZoom(map.getZoom()-1); featureLayer.setLabelingInfo([lc]); map.addLayer(featureLayer); }); }); </script> </head> <body class="claro"> <div id="mapDiv"></div> </body> </html>
... View more
02-22-2016
07:57 PM
|
0
|
6
|
2928
|
POST
|
Can anyone out there help me? I've written code to display a bounding box derived from coordinates, and want to display the scale bar. The specific scalebar code segment is: var scalebar = new Scalebar({ map: map,scalebarUnit: "metric",attachTo: "top-right" }); All else displays, but the scalebar does not. Below is the complete code: <!DOCTYPE html> <html> <head> <title>Bounding Box</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"> <link rel="stylesheet" href="https://js.arcgis.com/3.15/dijit/themes/claro/claro.css"> <link rel="stylesheet" href="https://js.arcgis.com/3.15/esri/css/esri.css"> <style> html, body, #mapDiv{ padding: 0; margin: 0; height: 100%; } </style> <script src="https://js.arcgis.com/3.15/"></script> <script> var URLExtent = this.location.href.split("=")[1].split("&")[0].split(","); require(["esri/map","esri/geometry/extent","esri/SpatialReference","esri/geometry/Polygon","esri/graphic","esri/symbols/SimpleFillSymbol" ,"esri/symbols/SimpleLineSymbol","esri/Color","esri/layers/GraphicsLayer","esri/dijit/Scalebar","dojo/on","dojo/domReady!"], function(Map,extent,SpatialReference,Polygon,Graphic,SimpleFillSymbol,SimpleLineSymbol,Color,Scalebar,on) { var arrayOfCoordinates = [[URLExtent[0],URLExtent[1]],[URLExtent[2],URLExtent[1]],[URLExtent[2],URLExtent[3]],[URLExtent[0],URLExtent[3]],[URLExtent[0],URLExtent[1]]]; var spatialRef = new esri.SpatialReference({wkid:4326}); var startExtent = new esri.geometry.Extent(URLExtent[0],URLExtent[1],URLExtent[2],URLExtent[3]); startExtent.spatialReference = spatialRef; map = new Map("mapDiv", { basemap: "streets" }); map.setExtent(startExtent,true); var box = new esri.geometry.Polygon(arrayOfCoordinates); var sfs = new SimpleFillSymbol(SimpleFillSymbol.STYLE_SOLID, new SimpleLineSymbol(SimpleLineSymbol.STYLE_DASHDOT, new Color([255,0,0]), 2),new Color([255,255,255,0.25]) ); map.on("load",function(){ var graphic = new Graphic(box,sfs); map.graphics.add(graphic); map.setZoom(map.getZoom()-1); }); var scalebar = new Scalebar({ map: map,scalebarUnit: "metric",attachTo: "top-right" }); }); </script> </head> <body class="claro"> <div id="mapDiv"></div> </body> </html>
... View more
02-16-2016
03:07 PM
|
0
|
2
|
2279
|
POST
|
Can anyone out there advise me please? When I start ArcMAP 10.3.1 (running on Windows 7 professional) the startup sequence proceeds to the point where the application notes it is "loading document". It then stops with no message. This occurs also with the 3D analyst extension. ArcCatalog opens. I have renamed the ESRI folder in the LocalApps folder, and the default.gdb, as advised, and have uninstalled and re-installed ArcGIS. However the problem persists. The only event that occurred between me last using ArcMAP successfully and this problem was an installation of the most recent python and an unsuccessful installation of PyScripter (it also doesn't work). I have uninstalled both before re-installing ArcGIS. No success. Any assistance would be appreciated. Richard MacNeill
... View more
01-24-2016
01:33 PM
|
0
|
4
|
4241
|
POST
|
UNCLASSIFIED Thanks Robert I've removed the var map = this.map and the two succeeding var statements. I'm still not getting any response from the map.addLayer(featureLayer) and am beginning to think the problem lies in the layer requested. Any thoughts. Thanks Richard
... View more
01-21-2016
08:42 PM
|
0
|
1
|
300
|
POST
|
UNCLASSIFIED Many thanks for your previous assistance. Can you help me here? I'm a new user attempting to get my head around Widgets and Javascript. I'm trying to add a layer to test further script, and am encountering a problem (see code below). The function below is accessed, so that my first two alerts respond. However, the "map.addLayer( ) command does respond and I receive no final alert. Is there something straightforward that I'm not getting? Commenting out the mode: and outfields: makes no difference. alert("Adding Layer"); require(["esri/map","esri/layers/FeatureLayer","dojo/domReady!"], function(map,FeatureLayer) { var map = this.map; var extent = map.extent; var mapSpatRef = map.spatialReference; var featureLayer = new FeatureLayer("http://sampleserver6.arcgisonline.com/arcgis/rest/services/USA/MapServer/3",{ mode: FeatureLayer.MODE_ONDEMAND, outFields: ["*"] }); map.addLayer(featureLayer); alert("Layer added"); }); ... Thanks Richard MacNeill
... View more
01-21-2016
02:17 PM
|
0
|
3
|
300
|
POST
|
UNCLASSIFIED Apologies Robert. All is good and all themes and widgets are visible. The problem was on our side. Your advice has been extremely useful. Richard MacNeill | SENIOR GEOSPATIAL SPECIALIST Geospatial Services | Melbourne Telephone: (03) 9920 3001
... View more
01-13-2016
05:51 PM
|
0
|
5
|
690
|
POST
|
UNCLASSIFIED Bad news I'm afraid. I replaced the copy of the repoitems file that I had removed and redeployed my widget. Then restarted the WebApp builder. Now when I edit an app, my Theme tab is empty and there are no available widgets at all. This is clearly a more serious problem but may involve a simple link. Do you have any suggestions? Richard
... View more
01-13-2016
04:16 PM
|
0
|
0
|
300
|
POST
|
UNCLASSIFIED Thanks Robert I have taken the liberty of attaching the zipped file folder. I'm a newby at this (at least the widget side of things), so the attached is the most simple of widgets basically saying hello. It is identical to that which was visible before the file removal (which I have a backup of). I did see that there is another file is the server/db folder - apps - that seems also to be recreated. Should I delete this also? Richard
... View more
01-13-2016
03:45 PM
|
0
|
0
|
690
|
Title | Kudos | Posted |
---|---|---|
1 | 01-26-2016 01:19 PM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|