Replies: 1 comment 1 reply
-
Thanks for sharing! This tool map help with creating the .lyrx files and deal with the illegal file name characters. Out of curiosity, does the geoprocessing tool "Save To Layer File" under Data Management not provide similar functionality? For the record, I have not used either method (your code, or Save To Layer File) for submittals yet. Love to hear your thoughts! -Ry |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In my efforts to speed up the creation of GeMS map packages, one thing that always seemed to take more time than it should was exporting layer files for the map. I typically did it manually, right-clicking each layer and saving the layer file. Well, no more! Here's a Python script that can be added to a toolbox or run from the Python window in ArcGIS Pro. I added it to the "Finalize" group of tools in my copy of the GeMS toolbox. See the script notes for more info.
In other good news, this fall ArcGIS Pro 3.2 will debut the "Save items to style" in the Share ribbon Save As section, similar to the ArcMap "Export map styles" tool. [CONFIRMED! THIS WORKS!]
UPDATE 1: Fixed a problem with annotation "sublayers" causing script to fail.
UPDATE 2: Added ability to save layer files with relative paths to data sources and added better error handling
Beta Was this translation helpful? Give feedback.
All reactions