|
DOC
|
Basic toolbox to create box polygons from point inputs. Created as a 'how-to' for this thread: How to create a Polygon from a single point
... View more
08-18-2014
10:27 PM
|
0
|
0
|
3436
|
|
POST
|
I have never seen that error before. However a Google search shows some results: AutomationException: 0x80040154 - Class not registered AutomationException: 0x80040154 - Class not registered com.esri.arcgis.interop.NativeObjRef ArcEngine on Linux RHEL, unresolved libshlwapi.so Most seem to suggest that one of the ESRI DLL files has not been registered with the system. This is in the context of COM registration and not ESRI licensing.
... View more
08-18-2014
09:15 PM
|
0
|
0
|
919
|
|
POST
|
I have only worked with .Net ArcObjects but this page has some information on working with fields using Java: ArcObjects Help for Java developers The main difference I can see with your code is that field is declared as Field and not IField:
for (int index = 0; index < fields.getFieldCount(); index++) {
//Get the field at the specified index
Field field = (Field) fields.getField(index);
if (field == null) {
System.out.println("Field is null ");
continue;
}
The ESRI sample on the help page declares field as IField (it is also declared before the for loop):
// get the Fields collection from the feature class
IFields fields = featureClass.getFields();
IField field;
// on a zero based index iterate through the fields in the collection
for (int i = 0; i < fields.getFieldCount(); i++){
// get the field at the given index
field = fields.getField(i);
if (!field.getName().equals(field.getAliasName())){
System.out.println(field.getName() + ":" + field.getAliasName());
}
}
... View more
08-17-2014
08:10 PM
|
1
|
0
|
974
|
|
POST
|
Check out the ESRI documentation and samples at: ArcGIS SDK for Java | ArcGIS for Developers The SDK site has the downloads and tutorials to get started. This page shows how to connect to ArcGIS Server layers: Add a map to your app—ArcGIS Runtime SDK for Java | ArcGIS for Developers
... View more
08-17-2014
07:59 PM
|
0
|
2
|
919
|
|
POST
|
Sounds like you need to use a Definition Query to filter your data. This will allow you to display only selected categories and then join data or do other analysis on a subset of your entire shapefile.
... View more
08-17-2014
07:47 PM
|
0
|
0
|
685
|
|
POST
|
The Using the proxy | Guide | ArcGIS API for JavaScript page describes the cases in which you may require a proxy. However, having a proxy configured doesn't change the way that you create and use the geometry service in your code. I would start by using some debugging tools to determine exactly why the request is failing. Can you post the URL to the published site?
... View more
08-13-2014
07:28 PM
|
0
|
4
|
1865
|
|
POST
|
Hi Ryan, You can try using Chrome Developer Tools or IE debugging to get more information about errors. One thing with geometry services is that they often require a proxy to be configured. Owen
... View more
08-13-2014
07:08 PM
|
0
|
19
|
2893
|
|
POST
|
Hi Rickey, I have commented the sections you may need to change:
function mapReady(map) {
dojo.connect(map, "onClick", executeIdentifyTask);
//create identify tasks and setup parameters
identifyTask = new esri.tasks.IdentifyTask("http://gis.ashland.or.us/arcgis/rest/services/cemetery/MapServer");
identifyParams = new esri.tasks.IdentifyParameters();
identifyParams.tolerance = 10;
identifyParams.returnGeometry = true;
// identifyParams.layerIds = [3,1,0]; <-- Remove this line from here
identifyParams.layerOption = esri.tasks.IdentifyParameters.LAYER_OPTION_ALL;
identifyParams.width = map.width;
identifyParams.height = map.height;
dojo.addClass(map.infoWindow.domNode, "myTheme");
}
function executeIdentifyTask(evt) {
identifyParams.geometry = evt.mapPoint;
identifyParams.mapExtent = map.extent;
// Add your required layer ids and zoom level here
if (map.getZoom() > 16) {
identifyParams.layerIds = [3,1,0]; // Identify all
} else {
identifyParams.layerIds = [3]; // Identify photos only
}
var deferred = identifyTask.execute(identifyParams);
deferred.addCallback(function(response) {
// response is an array of identify result objects
// Let's return an array of features.
return dojo.map(response, function(result) {
var feature = result.feature;
// ... etc ...
Basically, don't set the layer ids when you define the initial identify parameters (line 11 above). Set the layer ids when the identify task is about to execute so you can check the current map extent (lines 23-28 above). This way you are defining the layers to include dynamically based on the current map zoom level. Hope this helps. Owen
... View more
08-13-2014
06:19 PM
|
0
|
1
|
1762
|
|
POST
|
Very nice - this works great and is very simple. The results are identical to my long-winded process.
... View more
08-12-2014
06:41 PM
|
1
|
0
|
4786
|
|
POST
|
If you want to calculate this for a line feature class you can follow these steps - not sure if there is a simpler way but it works Make sure you have a unique field that identifies each line, for example copy the object id into a new field called LineID. Add the following fields to your data: StartX, StartY, EndX, EndY, LineDist (all double field type) Open the attribute table, right-click on the new field headers and use the Calculate Geometry option to populate the fields (X Coordinate of Line Start, Y Coordinate of Line Start, etc) From the attribute table Export the data as PointData and add it to the map (this makes the next step easier). Go to File > Add Data > Add XY Data and select your PointData table. Set your X and Y from your StartX and StartY. When the layer is added, right click on it and export the point feature class as StartPoints. Repeat steps 5-7 to create the EndPoints feature class. Use the Merge tool to combine StartPoints and EndPoints into a single AllPoints feature class. Use the Points to Line tool to create lines from your points. Select LinePoints as your input, specify an output feature class and make sure to select LineID as your Line Field parameter. Now you should have a new feature class with straight lines between your original start and end points. Open the attribute table and the lengths are all there. You can join this data back to your original line feature class using the LineID and calculate LineDist = Shape_Length (from the join data).
... View more
08-12-2014
05:48 PM
|
1
|
1
|
4786
|
|
POST
|
Kelly has a great answer. For example calling the sample page with parcel ids: http://developers.arcgis.com/javascript/samples/exp_history/?parcelid=1919427026 http://developers.arcgis.com/javascript/samples/exp_history/?parcelid=1919427014 Once this is set up you just need to code your links from the other page to open in a new window:
<a href="http://developers.arcgis.com/javascript/samples/exp_history/?parcelid=1919427026" target="_blank">5190 Clarendon Crest Dr</a>
<br/>
<a href="http://developers.arcgis.com/javascript/samples/exp_history/?parcelid=1919427014" target="_blank">5157 Nob Hill Ct</a>
... View more
08-12-2014
04:40 PM
|
2
|
0
|
941
|
|
POST
|
I noticed that the ESRI sample for the Undo Manager uses the old connect style: Graphics with undo redo | ArcGIS API for JavaScript After changing this sample to use the 'on' style event I also get an error. Adding some console.log lines shows the following: The 'on' function of the undo manager is undefined. Other 'on' functions are fine (such as the map.on above). Interestingly, using the alternate dojo.on style gives another message, for example the following results:
on(map, "load", function () {
console.log("on-map-load");
});
// console: on-map-load
on(undoManager, "change", checkUndoRedoState);
// Uncaught Error: Target must be an event emitter
Not sure if this is a bug. Owen Spatial XP
... View more
08-12-2014
04:30 PM
|
1
|
1
|
6633
|
|
POST
|
If you are using the Identify Task to query the features you could define your layer ids in the identify parameters dynamically based on the map zoom:
function init() {
map.on("click", doIdentify);
identifyTask = new IdentifyTask("http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/BloomfieldHillsMichigan/Parcels/MapServer");
// define static identify parameters
identifyParams = new IdentifyParameters();
identifyParams.tolerance = 3;
identifyParams.returnGeometry = true;
identifyParams.layerOption = IdentifyParameters.LAYER_OPTION_ALL;
identifyParams.width = map.width;
identifyParams.height = map.height;
//... etc ...
}
function doIdentify (event) {
map.graphics.clear();
// set layers to use based on zoom level
if (map.getZoom() > 16) {
identifyParams.layerIds = [0, 2];
} else {
identifyParams.layerIds = [2];
}
identifyParams.geometry = event.mapPoint;
identifyParams.mapExtent = map.extent;
identifyTask.execute(identifyParams, function (idResults) {
addToMap(idResults, event);
});
}
I created a Zoom Based Identify Sample on JS Bin. This is a quick re-work of an ESRI sample that limits the identification of buildings until you zoom in above level 16. When the map loads it will be at zoom level 16 and buildings are not included in the identify params when there is a map click event. As soon as you zoom in beyond level 16 then buildings are included via the identifyParams.layerIds property. Note that if you are not using a tiled base map you will need to check against map scale instead of zoom level. Hope this helps. Owen Spatial XP
... View more
08-12-2014
03:48 PM
|
2
|
3
|
1762
|
|
POST
|
What mode are you using when adding your feature layer? - MODE_AUTO, MODE_ONDEMAND, MODE_SELECTION, MODE_SNAPSHOP This setting can impact what features are loaded and when they are loaded. Do you have the full page code available?
... View more
08-11-2014
05:42 PM
|
0
|
0
|
1630
|
|
POST
|
I am not aware of any way to do this using arcpy but would also be interested to know if this functionality exists. The functionality *should* be part of arcpy describe but it doesn't seem to be exposed. It is obviously there in the underlying ArcObjects as the Layer Properties shows this in the Raster Information section: Also, note that as of ArcGIS 10 pyramids for file based rasters will be created as OVR files instead of RRD files. However this doesn't help if the raster is in a geodatabase. Owen Spatial XP
... View more
08-11-2014
05:29 PM
|
1
|
0
|
878
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 10-07-2014 06:13 PM | |
| 1 | 08-25-2015 02:04 AM | |
| 1 | 10-07-2014 03:54 PM | |
| 1 | 08-07-2014 09:19 PM | |
| 1 | 03-04-2015 02:02 PM |
| Online Status |
Offline
|
| Date Last Visited |
07-21-2021
06:32 PM
|