Integrating with Robotic Process Automation (RPA)

Loading

Integrating Robotic Process Automation (RPA) with Power Pages allows your web portal to trigger actions on legacy desktop systems or web interfaces that do not expose APIs. Microsoft provides this through Power Automate Desktop, enabling UI automation on local or remote machines as part of your portal-driven workflows.


What Is RPA in This Context?

RPA mimics human actions like clicking buttons, reading from Excel files, scraping data from websites, and entering information into software that doesn’t support direct integration.

For example:

  • A user submits a form via Power Pages.
  • Power Automate triggers an RPA bot.
  • The bot logs into a legacy desktop app and enters the submitted data.

Prerequisites

  1. Power Automate Desktop installed on the target machine (bot agent).
  2. On-premises data gateway for communication between cloud flow and local desktop.
  3. Attended or Unattended RPA license depending on whether a user is present.
  4. Access to Power Automate Portal to build both cloud and desktop flows.

Integration Workflow (Step-by-Step)


Step 1: Power Pages Form Setup

  • Design a form in Power Pages.
  • Connect it to a Dataverse table.
  • Ensure the form has all required data fields for the RPA process (e.g., customer ID, document number).

Step 2: Trigger Flow from Power Pages

In Power Automate (Cloud):

  1. Create a cloud flow:
    • Trigger: When a row is added (Dataverse)
    • Table: Connected to the form submission
  2. (Optional): Add a condition/filter to determine if RPA needs to run for this record.

Step 3: Call Desktop Flow

In your cloud flow:

  • Action: Run a desktop flow
  • Select your desktop flow
  • Choose Machine Group or Gateway
  • Input the required variables from the form (e.g., ID, date, status)

This will run your RPA bot in unattended mode on a connected device.


Step 4: Design Desktop Flow in Power Automate Desktop

  • Launch Power Automate Desktop
  • Create actions like:
    • Open application
    • Log in using credentials
    • Read/write to a form
    • Save or take screenshots
  • Use variables received from the cloud flow to guide execution

Example:

1. Launch CRM App
2. Enter Customer ID
3. Update case details
4. Save and exit

Step 5: Return Results to Dataverse

At the end of the flow:

  • Cloud flow resumes after desktop flow completes
  • Update the original Dataverse record:
    • Status = “Processed by RPA”
    • Log = “Completed at 10:45 AM”

You can also:

  • Notify users via email
  • Add audit logs
  • Store screenshots of automation output

Use Case Scenarios

  • Legacy ERP data entry after customer portal submission
  • Invoicing via desktop app after purchase
  • Ticket escalation into non-cloud ticketing systems
  • Updating HR systems from recruitment forms

Security & Licensing Tips

  • Secure access with environment roles and machine credentials
  • Monitor flows with Run History and Desktop Flow Logs
  • Choose Unattended RPA license for background processing

Best Practices

  • Use test environments for debugging
  • Add error handling in desktop flows
  • Schedule cleanup jobs to maintain machine performance
  • Use Queue-based triggers for scale (e.g., via Dataverse Queue table)

Leave a Reply

Your email address will not be published. Required fields are marked *