|
POST
|
Are you wanting to parse the values from the feature set and insert them into another feature class with the same coordinate system?
... View more
07-23-2015
04:20 PM
|
2
|
1
|
5036
|
|
POST
|
Are you trying to create a script tool that allows you to dynamically click on the map to create points as part of the gp tool's UI? If so, have you tried setting your input parameter type to Feature Set? Using the interactive feature and record input controls http://desktop.arcgis.com/en/desktop/latest/analyze/executing-tools/using-the-interactive-feature-and-record-input-con.htm Otherwise are you needing to implement a tool where you can wire into the OnMouseDown Event? Creating a Python add-in tool http://desktop.arcgis.com/en/desktop/latest/guide-books/python-addins/creating-an-add-in-tool.htm
... View more
07-23-2015
04:05 PM
|
2
|
3
|
5036
|
|
POST
|
Are you wanting to use python to make a REST call to the GPService or are you wanting to import the GPService as a tool within arcpy and allow arcpy to handle the rest call?
... View more
07-23-2015
12:57 PM
|
0
|
3
|
1446
|
|
POST
|
Prior to calling the tool you could open the map document with IMapDocument and then check or set the description using IDocumentInfo. I believe that description is the Comments property. IDocumentInfo Interface http://resources.arcgis.com/en/help/arcobjects-net/componenthelp/index.html#/IDocumentInfo_Interface/0012000003z3000000/
... View more
07-22-2015
01:38 PM
|
0
|
3
|
2752
|
|
POST
|
This is a limitation of ModelBuilder. Once you mark a parameter as a model parameter it can only derive its type from the current type of the parameter. This means if the parameter you flag is derived the model will treat it as derived. If you want to manipulate this in ModelBuilder you would need to present your data using a tool that provides derived output (i.e. the output is predetermined and cannot be modified by user input). A quick way to do this is to use the Calculate Value tool in ModelBuilder. I typically either use this approach or create a script tool to intercept and present the ModelBuilder outputs. Unlike ModelBuilder, a script tool will allow me to explicitly set the type of the parameter.
... View more
07-22-2015
09:49 AM
|
2
|
0
|
3393
|
|
POST
|
I believe you'd need to move your iteration logic into a separate model. If this logic is within the same model as the create geodatabase tool it will try to create the geodatabase on every iteration. You can see the following page for more information on this process. Integrating a model within a model http://desktop.arcgis.com/en/desktop/latest/analyze/modelbuilder/integrating-model-within-a-model.htm Near the bottom of this page you'll see a section titled "Advanced use of model iterators". It will describe the problem you're running into.
... View more
07-22-2015
09:34 AM
|
1
|
3
|
6461
|
|
POST
|
I tested it on my machine and everything appears to work fine. I used the managed approach. string mxdPath = BrowseForFile("Map Document", "Map Document (*.mxd)|*.mxd");
Geoprocessor gp = new Geoprocessor {OverwriteOutput = true};
try
{
CreateMapTilePackage tool = new CreateMapTilePackage
{
in_map = mxdPath,
service_type = "ONLINE",
output_file = mxdPath.Replace(".mxd", ".tpk"),
format_type = "PNG",
level_of_detail = 3,
summary = "test",
tags = "test"
};
IGeoProcessorResult2 result = gp.Execute(tool, null) as IGeoProcessorResult2;
if (result.ReturnValue is string)
{
object sev = 0;
Console.WriteLine(gp.GetMessages(ref sev));
}
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
object sev = 2;
Console.WriteLine(gp.GetMessages(ref sev));
}
... View more
07-22-2015
09:28 AM
|
0
|
6
|
2752
|
|
POST
|
Are you needing to run the Create Map Tile Package data management tool against the geoprocessor? Create Map Tile Package http://desktop.arcgis.com/en/desktop/latest/tools/data-management-toolbox/create-map-tile-package.htm
... View more
07-22-2015
09:09 AM
|
1
|
7
|
2752
|
|
POST
|
See the following Esri Documentation and look for the section titled "Using Code Blocks" Calculate Field Examples http://desktop.arcgis.com/en/desktop/latest/manage-data/tables/calculate-field-examples.htm
... View more
07-20-2015
03:14 PM
|
0
|
0
|
1100
|
|
POST
|
You would need to implement both the ComboBox and an Application Extension. The Application Extension would need to listen for changes in the TOC and you'd need to build a hook to feed the values to the ComboBox. I haven't tested it, but I'm thinking it'd look something like this. import arcpy
import pythonaddins
class ComboBoxClass(object):
"""Implementation for ComboBox"""
def __init__(self):
self.items = list()
self.editable = self.enabled = True
self.dropdownWidth = self.width = 'WWWWWW'
ComboBoxClass._hook = self
class ExtensionClass(object):
"""Implementation for Application Extension """
def __init__(self):
self.enabled = True
ExtensionClass._hook = self
def itemAdded(self, new_item):
ComboBoxClass._hook.items.extend([new_item])
def itemDeleted(self, deleted_item):
ComboBoxClass._hook.items.remove(deleted_item)
... View more
07-16-2015
04:13 PM
|
2
|
1
|
943
|
|
POST
|
I agree with Jeff. IRowChanges would reflect when a non-geometry attribute is updated. IFeatureChanges would reflect when there are changes to the geometry. You could utilize these within an Editor Extension. IRowChanges Interface http://resources.arcgis.com/en/help/arcobjects-net/componenthelp/index.html#//0025000007vw000000 IFeatureChanges Interface http://resources.arcgis.com/en/help/arcobjects-net/componenthelp/index.html#//0025000002qp000000
... View more
07-16-2015
10:30 AM
|
1
|
0
|
1261
|
|
POST
|
If you're already executing the python script from task schedule using a batch file the easiest option would be to point to the python.exe you're needing to use. For example, 32-bit python to execute arcpy from batch against Desktop cd C:\Python\Python27\ArcGIS10.3
python Drive:\Path\To\Script.py <Arguments> 64-bit python to execute arcpy from batch against Desktop cd C:\Python\Python27\ArcGISx6410.3
python Drive:\Path\To\Script.py <Arguments>
64-bit python to execute arcpy from batch against Pro cd C:\Python\Python34
python Drive:\Path\To\Script.py <Arguments>
From the ArcMap UI you can handle this by requiring that some of your tools on run in the foreground (i.e. 32-bit). If the 64-bit background gp is installed then any tool run in the background would run in 64-bit. While you're developing the python code I would suggest using a IDE that allows you to specify the python executable. This would be easier than having to worry about the consequences of messing with the file associations on the machine. I typically work with the paid version of WingIDE and it will allow you to easily switch the python executable. For production I typically either write up a batch command to hard code the version of python to run against or I use python to write the batch file and fire off a DOS command to execute the batch file. Hope this helps.
... View more
07-15-2015
04:19 PM
|
1
|
1
|
3588
|
|
POST
|
I'd like to start by saying that you may want to purchase and review the following book. I had the honor of sitting next to the author my first two years in Esri and I believe that this book is priceless. Lining Up Data in ArcGIS: A Guide to Map Projections http://www.amazon.com/Lining-Up-Data-ArcGIS-Projections/dp/1589483421 You'll also want to read up on the following page to gain a high level understanding of Spatial References. Spatial References https://developers.arcgis.com/net/desktop/guide/spatial-references.htm In regards to setting the extents of the map view, you would be able to create a envelope with those coordinates and set the view in the runtime application to it. Depending on the dimensions of your screen in regards to the corners of your envelope the application may resize the extents to properly fit within the screen. You could quickly review this by going to the following sample for runtime .NET and updating it as follows. ArcGIS Tiled Map Service Layer https://developers.arcgis.com/net/sample-code/ArcGISTiledMapServiceLayerSample/ <Grid>
<esri:MapView x:Name="MyMapView">
<esri:Map InitialViewpoint="0,0,200,200,3857">
<esri:ArcGISTiledMapServiceLayer ServiceUri="http://services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer" />
</esri:Map>
</esri:MapView>
</Grid> The units will reflect the chosen coordinate system. In this case they would be Meters because I'm using the Web Mercator projection.
... View more
07-15-2015
04:07 PM
|
0
|
0
|
981
|
|
POST
|
Have you tried using the ListSubtypes function of the data access module to gather the subtypes for the needed table or feature class? List Subtypes http://desktop.arcgis.com/en/desktop/latest/analyze/arcpy-data-access/listsubtypes.htm The describe objects may also be useful for this workflow. You should be able to compile a tool that can parse out the subtype names needed and implement your workflow to process them. GDB Table Properties http://desktop.arcgis.com/en/desktop/latest/analyze/arcpy-functions/gdb-table-properties.htm
... View more
07-15-2015
03:55 PM
|
2
|
0
|
1074
|
|
POST
|
What is your scratch workspace set to? (Folder, File GDB, Personal GDB, Enterprise GDB)
... View more
07-15-2015
11:00 AM
|
0
|
1
|
3243
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 01-19-2016 04:45 AM | |
| 1 | 09-24-2015 06:45 AM | |
| 1 | 09-15-2015 10:49 AM | |
| 1 | 10-12-2015 03:07 PM | |
| 1 | 11-25-2015 09:10 AM |
| Online Status |
Offline
|
| Date Last Visited |
11-11-2020
02:23 AM
|