POST
|
Hi Marcus, If you goal is to allow someone to draw new features (e.g. lines, polygons, or points) on the map, you would need to add either a GraphicsLayer or a Feature Layer to your map. The following samples will likely help you get started: Add or remove graphics from a FeatureLayer Sketch widget However, if your goal is to save them, the easiest option is to create a Hosted Feature Layer in ArcGIS Online. You can then read and save your changes to this Hosted Feature Layer. To do this, you will need an ArcGIS Online account. If you do not already have such an account, you can sign-up for a free developer account at https://developers.arcgis.com/ which will provide you with a small amount of storage to get started. Once on the developer site with an account, you can create a hosted feature layer by going to the Layers section, then + Create data and choosing the New hosted layer (Feature layer) option. The page will then walk you through creating a new hosted feature layer. Once you have a hosted feature layer, you can follow this tutorial to add it to your ArcGIS API for JavaScript map: Add a feature layer. If you want to allow the end user to edit the features (e.g. add a new polygon), you will find instructions in the Edit feature data tutorial. Best of luck and have fun! David
... View more
04-12-2021
08:12 AM
|
0
|
0
|
660
|
POST
|
Could you explain what you mean by "active layer"? Do you mean the layer that was last clicked by the user in the table of content and that is highlighted in blue? Or are you looking for layers that are visible (checkbox checked)?
... View more
04-12-2021
07:48 AM
|
0
|
1
|
1708
|
POST
|
A small update regarding this issue: Starting at version 2.6, ArcGIS Pro no longer uses Internet Explorer but instead uses Chromium for it's web interfaces. Therefore, any suggestions above regarding Internet Explorer no longer apply. There are however, issues with Chromium components getting blocked on enterprise computers (e.g. at school or work), or with hardware acceleration. Esri is aware of these issue and is working on solutions. In the meantime its highly suggested that anyone still experiencing this reach out to technical support directly. You may find some solutions at: https://support.esri.com/en/Technical-Article/000025347
... View more
04-12-2021
07:34 AM
|
0
|
0
|
1982
|
POST
|
I can't get it to work either. The script works as expected when copy-pasted into the Python window, but when run as a script, it doesn't apply the join. Below is the script I modified to try and get it to work (but it did not): import arcpy
in_layer_name = 'Alpha'
join_table = 'C:\\Users\\dblanchard\\Desktop\\Python_Join\\Default.gdb\\Beta'
join_field = 'JID'
# Get the currently active map
aprx = arcpy.mp.ArcGISProject('CURRENT')
map = aprx.activeMap
# Get the in layer from the map
in_layer_list = map.listLayers(in_layer_name)
if len(in_layer_list) == 1:
in_layer = in_layer_list[0]
arcpy.management.AddJoin(in_layer, join_field, join_table, join_field, "KEEP_ALL")
aprx.save()
else:
arcpy.AddError('Found {} layers matching the "{}" name when only 1 was expected.'.format(len(in_layer_list), in_layer_name)) I also experienced this issue when using ModelBuilder. It works if I run it with the model open, but if I close the model and run it from the toolbox, it doesn't apply the join. I would suggest you log a support ticket if you have access to Esri Support. Unfortunately, I cannot log a support ticket on your behalf. A workaround which may be suitable for you is to use a Task. I have a tried a simple task which has the Add Join tool in it and it works as expected.
... View more
01-18-2021
07:39 AM
|
0
|
1
|
926
|
POST
|
I have not encountered the issue with ArcGIS Pro/Python 3.x and spatial indexes. But when I encountered this issues with ArcMap/Python 2.7, the solution was to use a database user who didn't have permission to modify the indexes (e.g. data_writer). You could try the same approach and see if the performance improves when using ArcGIS Pro/Python 3.x.
... View more
01-18-2021
06:53 AM
|
1
|
0
|
1109
|
POST
|
You say you run the script in ArcGIS Pro. Do you have it setup as a Toolbox script tool. Do you copy-paste it into the Python window? Or do you launch it from the Python window (if so, what command do you use to do that).
... View more
01-15-2021
12:17 PM
|
0
|
3
|
3069
|
POST
|
This is somewhat a shot in the dark, but check to make sure Internet Explorer is installed on your computer. You can check by going to your Windows settings > Apps (> Apps & Features) > Optional features, and look for Internet Explorer 11. I don't know whether this applies to ArcGIS Pro, but I do know other software like Microsoft Office may not load web pages when Internet Explorer 11 is missing.
... View more
01-15-2021
07:50 AM
|
0
|
2
|
2337
|
POST
|
No, Arcade cannot be used to modify geometry in a dataset. The only Arcade profile which allows edits is Field Calculate. However, modifying the SHAPE field will only result in data corruption. You should instead look into Python and specifically ArcPy as this scripting language has powerful geometry editing capabilities.
... View more
01-15-2021
07:08 AM
|
1
|
0
|
1110
|
POST
|
I would be careful with recalculating spatial indexes, especially on larger datasets or on enterprise databases. This can be a time consuming operation and could impact other users of the dataset. Unfortunately, I am not aware of a way of validating the spatial reference via a script.
... View more
01-15-2021
06:37 AM
|
0
|
0
|
1933
|
POST
|
@Anonymous Userhas the right idea. I'll just add that once you've looped over an item that you want to backup, there functions like export (for GIS data), download (for files), and download_metadata that will help you save the content locally.
... View more
01-15-2021
06:27 AM
|
1
|
0
|
1780
|
POST
|
If I understand correctly, when you perform the join using the geoprocessing tool or model builder, you get the expected behaviour. However, running the join from a Python script you saved from the geoprocessing tool results, your dataset does not get joined? Where are you running your script file from, and where are you expecting to see the results? For example, are you running the Python script file by double-clicking it in Windows, and then looking for the result in ArcGIS Pro?
... View more
01-15-2021
06:20 AM
|
0
|
5
|
3084
|
POST
|
I believe you should be able to do a GetCapabilities operation on the WMTS service just like you can with a WMS service. If so, just get that data ahead of time before creating the layer in the ArcGIS API. You could then check the returned XML for the appropriate projection data. Spatial references are usually prefixed with "EPSG".
... View more
11-15-2017
01:57 PM
|
1
|
0
|
458
|
POST
|
To the best of my knowledge, individual graphics within a graphics layer do not provide any guarantees as to how they will be ordered. The fact that graphics using SimpleLineSymbols are layered in the order in which they are added is most likely just a coincidence of the way the API was written and could change with any new version. If you need a specific ordering, you should look a creating multiple Graphics Layers and ordering those.
... View more
11-15-2017
01:35 PM
|
0
|
1
|
523
|
POST
|
The most common issue with WMTS layers is with the GetCapabilities request which returns an XML file. If that XML file is located on a server that is different then the one serving your application, it will be blocked by the browser. This is because XML files are not supported for CORS. You can find whether that is the issue by opening your browser's developer console (usually with F12 on Windows). After reloading the page, you might find an error there indicating that a request was blocked for security reasons. If that is the case, try using a proxy page.
... View more
11-15-2017
01:21 PM
|
1
|
0
|
575
|
POST
|
The way to call stored procedures from ArcPy has not changed with SQL Server 2014. I work on a project that runs the stored procedure using sde_Conn.execute("exec dbo.MyStoredProcedure(...)) in SQL Server 2014. The error you are getting is due to a difference in the way SQL Server fetches metadata starting with SQL Server 2012. A quick web search reveals several possible solution. You may be able to resolve this issue by replacing the temporary table with a Common Table Expression or a Table Variable. There could also be issues with your returned dataset (if you're returning anything). I know the WITH RESULTS SETS syntax allows you to explicitly set the format, but I'm not particularly familiar with it.
... View more
11-15-2017
01:02 PM
|
0
|
0
|
1288
|
Title | Kudos | Posted |
---|---|---|
1 | 04-21-2016 11:31 AM | |
1 | 01-15-2021 06:27 AM | |
1 | 01-18-2021 06:53 AM | |
1 | 01-15-2021 07:08 AM | |
1 | 01-14-2015 10:30 AM |
Online Status |
Offline
|
Date Last Visited |
05-19-2022
09:05 AM
|