Synthèse
Encrypts a Python toolbox file.
Attention :
The encryption of a Python toolbox is performed in place and will overwrite the original unencrypted .pyt file. It is recommended to back up the input file to avoid the loss of its contents in case the password is forgotten.
Discussion
A Python toolbox can also be encrypted by clicking on the toolbox within ArcGIS Pro.
Syntaxe
EncryptPYT (toolbox, password)
Paramètre | Explication | Type de données |
toolbox | The Python toolbox that will be encrypted in place. | String |
password | The password used to lock the encrypted Python toolbox. | String |
Exemple de code
Encrypt a Python toolbox.
import arcpy
toolbox = 'd:/tools/analysis.pyt'
password = '<your password>'
arcpy.EncryptPYT(toolbox, password)
Rubriques connexes
Vous avez un commentaire à formuler concernant cette rubrique ?