Day 5 - Advanced Topics and Optimisation

Learn how to make your automations resilient, efficient, and production-ready by applying advanced techniques such as exception handling, optimisation, and process standardisation.

Help CentreGetting Started

Day 5 - Advanced Topics and Optimisation

The goal is to learn how to make your automations resilient, efficient, and production-ready by applying advanced techniques such as exception handling, optimisation, and process standardisation.


1. Building Reliable Automations

Even a well-tested process can fail unexpectedly - a slow website, a renamed button, or a missing file. Advanced RPA developers prepare for these situations with error handling, timeouts, and recovery logic.


Objective: A reliable process doesn't just work - it recovers gracefully.


2. Exception Handling

What Is Exception Handling?

Exception handling is the technique of anticipating, catching, and responding to errors during execution. It ensures that when something goes wrong, the process:

  • Logs what happened.

  • Handles the failure safely.

  • Optionally continues with the next task.

  • Optionally closes all windows and restarts the process


Common Types of Exceptions

TypeDescriptionExample
System ExceptionApplication or OS-level issuesApp crash, missing file
Business ExceptionRule or data validation errorsInvalid invoice amount
Selector ExceptionUI element or Window not foundMoved or renamed button
Timeout ExceptionAction took too longSlow response or network delay

How to Handle Exceptions in Automize

  1. Select a key activity (e.g., "Click Button").

  2. Add a connector of type "Exception."

  3. Connect it to an error-handling block (e.g., "Log", "Notify", "Raise an Error", or "Take a Screenshot").

  4. Optionally loop back to an earlier activity to try again.

  5. When looping back, be sure to add a Maximum value for the connection to prevent indefinite loops.

  6. End gracefully or return to a known state.

Tip: Always log exceptions clearly, including process name, step, and variable values.


Hands-On Exercise: Exception Flow

Objective: Handle an app crash gracefully.


Steps:

  1. Open your Calculator process.

  2. Add a Decision after launching Calculator:

    • If the Calculator window does not exist,→ Log: "Calculator failed to open."→ End process.

  3. Add an Exception connector from the "Click Equals" step to a "Handle Error" sub-process:

    • Log: "Calculation failed at step {ActivityName}."

  4. Test by closing Calculator mid-run.

Success Criteria:The process logs the failure and ends cleanly instead of freezing or crashing.


3. Optimising Performance

Automation performance depends on efficiency and structure - not speed alone.


Techniques for Faster, Smarter Automation

  1. Reduce Unnecessary Steps

    • Combine repetitive actions into sub-processes.

    • Remove redundant "click" or "wait" steps.

  2. Use Smart Waits

    • Instead of setting fixed wait periods on connections (i.e. = 5 seconds), replace with "Test if Element exists" or "Test if Window. exists" and set the connection wait to "at most."

  3. Minimise Data Operations

    • Filter or sort data before looping.

    • Load only what's needed from Excel or Outlook.

  4. Re-use Assets

    • Create standard sub-processes for login, file read/write, email send, etc.

  5. Optimise Loops

    • Break long loops into smaller batches.

    • Stop looping once goals are met.

Pro Tip:A smaller, well-structured process will outperform a single long automation every time.


Hands-On Exercise: Process Optimisation

Objective: Optimise a process with long delays and redundant steps.


Steps:

  1. Open a process that uses fixed connection times.

  2. Where consecutive activities happen (all within the same application), reduce the connection times to = 0.2 seconds.

  3. Where waiting for elements or windows are required, change the connection's waiting times to > 10 seconds (as an example), and insert "Test if Window exists"

  4. Replace each fixed wait with Wait for Element Exists.

  5. Remove duplicate clicks or unused variables.

  6. Group related steps logically.

  7. Re-run and measure total runtime.

Goal: The process runs faster, with no loss in reliability.


4. Creating Reusable and Modular Processes

Reusable automations reduce development time and errors.


Sub-Processes

A sub-process is a smaller process that can be called by others - for example:

  • "Login to System"

  • "Read Excel Data"

  • "Send Notification Email"

Benefits:

  • Centralised updates (fix once, used everywhere).

  • Consistent standards across teams.

  • Easier debugging.

Best Practice: Build and store sub-processes in a dedicated Library → Components section.


Hands-On Exercise: Reuse a Sub-Process

Objective: Create and call a reusable login process. Any process used within another process, is called a sub-process.


Steps:

  1. Create a new process called "Login to Calculator."

    • Record opening Calculator, verify it's open, then stop.

  2. Open your main "Perform Calculation" process.

  3. Insert the "Login to Calculator" sub-process at the start.

  4. Run and verify both processes execute in sequence.

Goal: The main process successfully calls and completes the sub-process.


5. Process Readiness and Production Deployment

Before promoting any process to PRODUCTION, it should meet strict readiness criteria.


Production Checklist

CategoryChecks
ReliabilityAll steps run without failure under normal load.
Error HandlingException paths and logs exist for critical steps.
PerformanceTotal runtime optimised; unnecessary waits removed.
VariablesAll variables have default values; none are hardcoded.
SelectorsStable and verified against app updates.
DocumentationComments, purpose, and version history included.
EnvironmentCorrect DEV → TEST → STAGING → PROD progression used.

Pro Tip: Have a peer review your process before moving to production - a second set of eyes catches what you miss.


6. Final Hands-On Challenge - End-to-End Automation

Challenge: Invoice Processor

Objective: Create an end-to-end automation combining everything learned this week.


Scenario:

  • Read invoice data from a PDF file.

  • Open a website or app to enter the invoice data.

  • If the amount > 1000, mark it as "High Value".

  • Save confirmation results to a new Excel sheet.

  • Log all actions with timestamps.

  • Handle missing files gracefully.

Guidelines:

  1. Use variables for invoice fields.

  2. Use formulas to calculate totals or classifications.

  3. Add a loop to process all rows.

  4. Use exception handling for missing data.

  5. Log progress using Log Message at key points.

  6. End with a summary log like:

    Log: "Process completed - {CountSuccess} successful, {CountFailed} failed."

Success Criteria:The process runs end-to-end, handles errors, and produces a clear success log.


Optional Challenge: Multi-App Optimisation

Create a process that:

  1. Reads a list of names from Excel.

  2. Opens Outlook, drafts an email to each name.

  3. Logs sent status in Excel.

  4. Handles offline or missing data gracefully.

Goal: Demonstrate reliability across multiple applications.


7. Best Practices for Advanced RPA Development

1. Build for Change

Design with future updates in mind - avoid absolute selectors and hardcoded paths.


2. Handle Failures Gracefully

A failed step should never crash the process; it should log, recover, and move on.


3. Prioritise Readability

Your process should tell a story visually.If someone else can understand it at a glance, it's well-built.


4. Monitor and Measure

After deployment:

  • Review logs daily for anomalies.

  • Measure success rates and runtime trends.

  • Continuously refine high-volume processes.


5. Version Everything

Keep version numbers and notes (e.g., v1.2 - Added Exception for Timeout).This ensures traceability for auditing and rollback.


6. Follow Industry Standards

These are standard across major RPA platforms:

  • Separate development and production environments.

  • Maintain consistent naming, documentation, and testing frameworks.

  • Create reusable components for login, error handling, and logging.

  • Emphasise recoverability over perfection - it's okay to fail gracefully.


End of Day 5 Summary

By completing Day 5, you should now be able to:


✅ Design error-tolerant and resilient automations
✅ Implement exception handling and recovery logic
✅ Optimise performance and maintain clean process maps
✅ Build and reuse modular sub-processes
✅ Validate readiness for production deployment


Congratulations - You're Now an Automize RPA Developer!

You've completed the full Automize RPA Developer Training Series.You now have the skills to design, build, test, and optimise reliable automations that deliver real business value.


Continue expanding your skills through:

See it working on your own data

Everything documented here ships with the platform – try the document tools free, or go live in 7 days.