- 发行说明
- 入门指南
- 设置和配置
- 自动化项目
- 依赖项
- 工作流类型
- 文件比较
- 自动化最佳实践
- 源代码控件集成
- 调试
- 诊断工具
- 工作流分析器
- 变量
- 参数
- 导入的命名空间
- 控制流程
- 对象存储库
- 日志记录
- ScreenScrapeJavaSupport 工具
- Studio 测试
- 扩展程序
- 故障排除
Project templates can speed up automation design when used as a starting point for new automation projects. You can use one of the built-in templates or use custom templates from other sources, such as the organization-wide template feed. In addition, you can create and publish your own custom templates.
Studio 后台视图的“开始”选项卡上提供了以下内置项目模板:
-
备注:
如果从 2021.4 之前的版本更新 Studio 之后,您遇到诸如“开始”选项卡上未显示任何内置模板或固定/取消固定模板不起作用等问题,请执行以下操作之一,然后重新启动 Studio:
- 在文本编辑器中打开文件
C:\Users\<user>\AppData\Roaming\UiPath\UiStudio.v2.settings,将<HasCustomFavorites>元素的值设置为false。 - Go to Settings > General and select Reset settings. For more information about the settings that are reset, see Configuring Studio Settings.
- 在文本编辑器中打开文件
要从所有可用来源浏览和搜索自定义模板,请转到“主页”(后台视图),然后选择“选项卡。
自定义模板
可以将用户定义的流程或测试自动化项目保存为模板,以便在其他自动化项目中使用。此类模板可能包含一组特定的依赖项和内置工作流,其中具有已经定义的变量和参数,稍后可供在各种项目中使用。
Studio offers two ways to create your own custom templates, either by using the Template project type in the Home tab or by exporting a process, or test automation project as a template.
创建模板
-
在 Studio 后台视图的“新建项目”下,单击“模板”。
-
输入模板名称和描述,以及创建模板的位置。
-
在“流程”和“测试自动化”类型的模板之间进行选择,然后在 Visual Basic 和 C# 之间选择一种语言。
-
单击“创建”,模板将在 Studio 中打开。
将项目导出为模板
您可将流程或测试自动化项目导出为模板,发布到特定位置,然后在 Studio 后台视图中的“模板”选项卡中使其可用。
可以使用“导出为模板”功能区按钮导出在 Studio 中打开的流程、测试自动化项目或修改的内置模板。
导出时,模板保存在“位置”字段中的路径下。
在创建模板之前,在文件中进行的未保存更改将自动保存在项目中。
作为模板发布
Publishing templates is similar to publishing processes and libraries, with the exception that the wizard contains an additional step where to enter template information. For more information, see About Publishing Automation Projects.
浏览和使用模板
您可以在 Studio 后台视图的“模板”选项卡中查看所有可用的项目模板。
系统在顶部列出最近使用的模板。您可以按名称和描述搜索模板,选择是否包含预发行版本,或按位置筛选模板。
以下模板位置可用:
- 全部 - 所有位置。
- 内置 - 随 Studio 安装的模板。
- 官方 - 官方 UiPath 订阅源中的模板。
- Orchestrator - 组织范围内的模板订阅源,当连接到 Orchestrator 时可用。
- 本地 - 本地用户订阅源,默认情况下:
C:\Users\User\Documents\UiPath\.templates。可以通过在 Studio 后台视图中选择“设置”>“位置”来定义位置。 - 市场 - 已发布到 UiPath 市场的模板。
基于模板创建项目
- 单击模板。将打开一个包含有关模板的详细信息的窗口。
- 从窗口的左下角选择要使用的版本,然后单击“使用模板”。