public void SetDefaultToolboxPath( string defaultToolbox )
Public Sub SetDefaultToolboxPath( _ ByVal defaultToolbox As String _ )
Parameters
- defaultToolbox
- The full path to the toolbox that will be used
public void SetDefaultToolboxPath( string defaultToolbox )
Public Sub SetDefaultToolboxPath( _ ByVal defaultToolbox As String _ )
Exception | Description |
---|---|
ArcGIS.Core.CalledOnWrongThreadException | This method or property must be called within the lambda passed to QueuedTask.Run. |
System.ArgumentException | input path cannot be resolved as default toolbox. |
By default, a new toolbox is created in the project's home folder and used as its default toolbox. However, the default toolbox can be set to another existing toolbox. For example, if you create a new model from the Analysis tab on the ribbon in ArcGIS Pro, a new model is created in the default toolbox. A project is required to have a default toolbox.
The ArcGIS Pro application settings may specify a toolbox that should always be used as the default toolbox. Anyone using the project is expected to have write access to that toolbox. If a project's default toolbox is not available in the specified location, a toolbox will be created accordingly to satisfy the default toolbox path.
At this time, only standard toolboxes (*.tbx) in the file system should be used as a project's default toolbox. If the project's default toolbox is set to use a Python toolbox (*.pyt), creating a new model from the Analysis tab on the ribbon will fail; models can't be created in Python toolboxes.
Target Platforms: Windows 11, Windows 10