You need to enable JavaScript to run this app.
最新活动
大模型
产品
解决方案
定价
生态与合作
支持与服务
开发者
了解我们

如何提升UiPath性能?高性能活动推荐及需规避活动清单

Great question! Optimizing UiPath workflow performance is crucial for keeping your automations snappy, especially when dealing with large datasets or long-running processes. Let’s break this down into actionable tips, go-to activities for speed, and pitfalls to avoid.

1. General Tips to Boost UiPath Runtime Performance
  • Stabilize your selectors: Avoid dynamic attributes like id or className that change on page reload. Use stable identifiers like name or static xpath expressions. If you must use dynamic elements, use wildcards (*) or regex to make selectors more resilient—this cuts down on failed element searches and retries.
  • Minimize element interactions: Every time UiPath interacts with a UI element (like clicking or typing), it takes time. Cache frequently used elements with Cache Scope or store them in a variable upfront instead of re-finding them multiple times.
  • Optimize data handling: For DataTable operations, use built-in activities like Filter Data Table or Sort Data Table instead of looping through every row manually. These activities are optimized under the hood and way faster than custom loops.
  • Leverage parallel processing: Use Parallel For Each for tasks that don’t depend on each other (like processing multiple independent files). This splits the work across multiple threads and cuts down on total execution time.
  • Limit unnecessary logging: Too many LogMessage activities (especially at the Info or Debug level) can slow down your workflow. Stick to logging only critical events (errors, warnings) in production.
  • Close unused applications: Use Close Application or Kill Process to shut down apps you’re done with—this frees up system resources for your automation.
2. Activities That Improve Execution Speed

Here are the go-to activities to make your workflows run faster:

  • Parallel For Each: Perfect for processing collections (like lists of files, emails) where each item doesn’t rely on the previous one. It runs tasks in parallel, drastically reducing total runtime.
  • Filter Data Table / Sort Data Table: These native activities handle DataTable operations way more efficiently than writing custom For Each Row loops. They’re optimized to process data in bulk instead of row-by-row.
  • Get Attribute / Get Text: Instead of using Find Element followed by extracting text/attributes, use these direct activities to grab what you need in one step. Saves the overhead of separate element lookup and extraction.
  • Invoke Code: For complex logic (like heavy calculations or advanced DataTable manipulations), writing a snippet of C# or VB code in Invoke Code is often faster than chaining multiple UiPath activities. It cuts down on the overhead of activity execution.
  • Cache Scope: Wrap frequently accessed UI elements or data operations in this scope. It caches the results so UiPath doesn’t have to re-find elements or re-calculate values every time.
  • Use Application/Browser with Cache Elements enabled: This option caches all elements in the application/browser session, so UiPath doesn’t re-locate them on every interaction. Game-changer for repetitive UI tasks.
  • Write Range (batch Excel writes): Instead of looping through rows and using Type Into to write to Excel, use Write Range to dump an entire DataTable into Excel in one go. Way faster and less error-prone.
3. Activities to Avoid (or Use Sparingly)

These activities can slow down your workflow if overused—here’s what to watch out for:

  • For Each Row (with large DataTables): If you’re dealing with thousands of rows, looping through each one is extremely slow. Replace it with Filter Data Table, Invoke Code, or bulk operations whenever possible.
  • Frequent Find Element / Find Elements calls: Every time you use these, UiPath scans the UI to locate elements. If you need to access the same element multiple times, cache it in a variable or use Cache Scope instead.
  • Type Into for bulk data entry: Typing into fields one-by-one is slow. For Excel, use Write Range; for web forms, see if you can paste bulk data or use API calls instead of manual typing.
  • Unnecessary Delay activities: Instead of using fixed Delay times (like 5 seconds), use conditional waits like Wait Element Visible or Wait Element Enabled. These wait only as long as needed, avoiding wasted time.
  • Excel Application Scope when not needed: If you’re just reading/writing data without needing to interact with the Excel UI, use the standalone Read Range/Write Range activities. They don’t spin up an Excel process, which saves resources.
  • Overusing Attach Window / Attach Browser: If you’re already in a Use Application/Browser scope, you don’t need to re-attach the window every time. Stick to one scope per application session.

Remember, always test your optimizations! A change that speeds up one workflow might not work the same for another—balance performance with functionality to make sure your automation still does what it’s supposed to.

内容的提问来源于stack exchange,提问作者Suresh Chandrasekar

火山引擎 最新活动