A Library is a package which contains multiple reusable components. Libraries are saved as
.nupkg files and can be installed as dependencies to workflows using Package Manager.
For example, you could create a library that collects data from an Excel spreadsheet and appends it to another, as explained in the Creating a Basic Library page. Next, the library can be packaged and used in other processes as an activity.
A reusable component activity represents one or more workflows packaged together as a
.nupkg file, and utilized in other processes.
- 转到“Studio 后台视图”>“开始”>“库”。这将打开新建空白库窗口。
- Fill in the name and pick a location for the library. The default location is
C:\Users\<current_user>\Documents\UiPath. Add a description and select Create. The new library is created and saved on your local machine.
Note: The library name cannot exceed 128 characters, and the description cannot exceed 500 characters.
Add a tooltip and help link to a library by opening the Properties window.
The tooltip is visible in the Activities panel after you've added the new activity. The Help Link opens when you press F1 on the selected activity.
When creating a new library from a template, the Designer panel doesn’t automatically open the
.xaml file, unless the library template has a
Add an annotation to a used argument in the library to have it displayed later as a tooltip in the activity's Properties panel. Read the Arguments Panel to find out more about adding annotations to arguments.
""）将 null 值分配给变量。如此一来，在将打包的库作为依赖项用于项目中时，便能避免发生任何不一致的情况。
To configure the settings of a library project, open the Project Settings window by clicking Settings in the Project panel.
The following options are available in the General tab:
- Name - edit the name of the project.
- Description - edit the description of the project.
- Include Sources - set to Yes to package all
.xamlsources within the generated assembly file, including workflows that were previously made private. This is helpful during debugging workflows.
- Compile activities expressions - set to Yes to compile and package all activities expressions with the library. This results in an improved execution time.
- Modern Design Experience - set to Yes to enable a modern experience of working with UI Automation, including new and improved activities, recorders, and wizards, as well as the Object Repository.
Publishing libraries is similar to publishing processes. For more information, see About Publishing Automation Projects.
When publishing libraries, take into account the following limitations:
- Due to NuGet limitations:
- You cannot publish libraries to locations that contain user-restricted subfolders using Windows environment path variables.
- Release notes for published libraries are visible only in Orchestrator.
- Libraries with special characters in the names of
.xamlfiles they contain may not be successfully published.
- Libraries containing Invoke Workflow File activities with the Isolated option selected cannot be published. An error message is displayed in the Output panel.
- When using Invoke Workflow File activity, make sure the invoked file is located in the same folder as the library project.
- The Launch Workflow Interactive activity is not supported for libraries.
- Using Invoke Workflow File inside a library to reference the library itself is not supported.
- 库是向前兼容的，这意味着它们只能用于使用 Studio v2018.3 及更高版本创建的项目。库不能发布到版本低于 2018.3 的 Orchestrator。
- 当您运行的项目包含自定义活动的项目时，可能会发生错误，这些自定义活动来自在 2019.10.1 之前的 Studio 版本中创建并通过 Studio 2019.10.1 或更高版本发布的库中。在这种情况下，您必须重新创建并重新发布库。
Please note that in a library project, when using Import Workflows to add a workflow that contains a library, the dependencies referenced in the library are not imported.
When importing two versions of the same custom library to a project in Studio, the extra custom activities contained only in the second library are not visible in the Activities panel unless you remove the first imported library.
Updated about a month ago