- Erste Schritte
- Für Administrators
- RPA-Workflow-Projekte
- Erstellen eines RPA-Workflows aus einer Idee
- Erstellen eines Projekts
- So starten Sie einen RPA-Workflow
- Verwalten von Projektdateien und -ordnern
- Verbinden von RPA-Workflows mit Ihren Konten
- Konfigurieren von Aktivitäten
- Verwalten der Aktivitäten in einem Projekt
- Übergeben von Werten zwischen Aktivitäten
- Iterieren durch Elemente
- Verwalten der Daten in einem Projekt
- Konfigurieren eines Projekts zur Verwendung Ihrer Daten
- Verwenden von Datei- und Ordnerressourcen
- Lokale Einrichtung für RPA-Workflow- und App-Projekte
- App-Projekte
- Apps in Studio Web
- Entwerfen von App-Projekten
- Debuggen von App-Projekten
- Veröffentlichen, Bereitstellen und Aktualisieren von App-Projekten
- Importieren und Exportieren von App-Projekten
- Arbeiten mit Entitäten in einem App-Projekt
- Erstellen zugänglicher Apps
- Hinzufügen zugänglicher Deskriptoren
- Die Beschriftung „Zugänglich“.
- Verwenden des Registerkartensteuerelements für Barrierefreiheit
- Entwerfen barrierefreier Listen und Überschriften
- reaktionsfähiges App-Design
- Farbkontrastverhältnis
- Legen Sie Stile und Zuordnungen auf Aria-Ebene für das Header-Steuerelement vor
- Bekannte Einschränkungen
- Legen Sie einen externen Kontext mithilfe von Abfrageparametern fest
- Legen Sie einen externen Kontext mithilfe externer Ereignisse fest
- Verwenden Sie Arrays, um Dropdown-Menüs, Dropdown-Menüs mit Mehrfachauswahl und Optionsfeld-Steuerelemente auszufüllen
- Verwenden Sie tabellarische Steuerelemente mit Data Service-Entitäten in App-Projekten
- Integrieren Sie Konversations-Agents
- App-Aktivitäten
- Agent-Prozesse
- Maestro-Fall
- Flow-Arbeitsfläche in Maestro Orchestrate
- Agents
- Functions
- Functions
- Solutions (Lösungen)
- API-Workflows
- Tests
Functions
Add a Python or TypeScript/JavaScript function to a Studio Web solution, set it up from a sample or from your IDE, debug it, and call it from other projects in the solution.
A function is a project that holds code-first logic, written in Python or in TypeScript/JavaScript. You add a function to a solution, and the other projects in the solution call it as a job. For how to write functions with the SDKs and the UiPath CLI, refer to About Functions in the Functions guide.
What you can do with a function in Studio Web depends on its language:
| Aktion | Python | TypeScript/JavaScript |
|---|---|---|
| View the code | Ja | Ja |
| Edit the code | No. Edit the code in your IDE, then push it to Studio Web. | Ja |
| Debug, with breakpoints | Ja | Ja |
Add a function to a solution
You can add a function only to an existing solution. The Start building window doesn't list it.
- Öffnen Sie die Lösung in Studio Web.
- In the Explorer panel, select Add to solution.
- Under Building blocks, select Function.
Studio Web adds the project to the solution and opens the Setup your function page. To set up the function, start from a sample or bring the code from your IDE.
Set up a function from a sample
-
On the Setup your function page, under Quick start, select Python or TypeScript / JavaScript.
If the page doesn't show a language choice, only Python functions are available in your organization.
-
Select Start with a simple sample.
Studio Web adds the sample files to the project and opens the code file. The Python sample adds two numbers. The TypeScript sample returns a greeting.
Both samples run as jobs. To build an HTTP function, which a coded app calls as its backend, refer to HTTP triggers and routing in the Functions guide.
Set up a function from your IDE
In a Cloud Workspace solution
- If the Setup your function page shows a language choice under Quick start, select the language of your function.
- Under Sync from your IDE into Studio, copy the project key, and add it to the
.envfile of your function project. - Push the project from your IDE with the command shown on the page:
uipath pushfor Python, oruip function pushfor TypeScript/JavaScript.
For how to create a function project in your IDE, refer to Getting started for Python, or Getting started with JavaScript.
For the options of the push command for TypeScript/JavaScript, refer to uip function push in the UiPath CLI guide.
In a Local Workspace solution
In a solution stored on your machine, the Setup your function page shows Add your project instead of the sync steps.
- Create the function project in your IDE. For a Python function, generate it with
uipath init --type function. - Add the project files to the solution folder, the local folder that Studio Web uses to access your project files.
For more information about local solutions, refer to Solutions in the Local Workspace.
Debug a function
- Optional: in the Properties panel of the function, choose the function to debug in the Entrypoint list.
- In the toolbar, open the Debug menu and select Debug configuration.
- On the Entrypoint arguments tab, under Input Arguments, enter a value for each input of the function. The fields match the input that the function declares.
- Optional: under Environment Variables, define the environment variables that the function reads at runtime. Studio Web masks secrets in the editor.
- Wählen Sie Speichern.
- Optional: to pause the run on a line, select the area to the left of the line number to add a breakpoint.
- In the toolbar, select Debug.
The Logs panel shows the progress of the run and the output of the function. The bottom panel shows the execution trace, with the input and output of each traced step. When the run pauses at a breakpoint, use Continue, Next step, or Stop in the toolbar.
Call a function from another project
To call a function from an RPA workflow in the same solution:
- Open the RPA workflow and add the Run Job activity.
- In Process name, select the function under Defined resources.
- Select Input arguments.
- In the Data Mapping window, map each input of the function to a variable.
- Wählen Sie Speichern.
For the other ways to call a function, such as from a Maestro process, an agent, or an app, refer to Invoking functions in the Functions guide.
Publish a function
You can't publish a function project on its own. Studio Web publishes and deploys a function with its solution. For details, refer to Publishing and deploying solutions.