I am looking for a python code that allows me to name an output file(shapefile/dbf) based on input file +user defined suffix. Thereafter I would like to save the output file to a workspace.
via command line or as a python script tool?
without more info, something along the lines of:
import os in_file = arcpy.GetParameterAsText(0) output_workspace = arcpy.GetParameterAsText(1) out_suffix = arcpy.GetParameterAsText(2) out_name = os.path.basename out_name += out_suffix out_filepath = os.path.join(output_workspace, out_name)
As a Python script tool.
So will the above fit into your existing script? do you understand it etc.?
Angemeldete Mitglieder können Beiträge verfassen, Updates folgen und mehr. Neu hier? Registriere ein kostenloses Konto.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.