I want to have a report generated on daily basis for the number of orders creation request came in, number of orders processed and failed. I have to include graphs in the report. Please tell me the ways to do this.
Use UiPath activities to retrieve order data from your database, application, or data source. This could involve running SQL queries, reading from an Excel file, or extracting from a web application.
Step 2: Process Data
Use data manipulation activities to count the number of requests, processed orders, and failed orders. You can use the ‘Filter Data Table’ activity, LINQ queries, or other data processing techniques.
Step 3: Generate Report
Create a report template in Excel with placeholders for the counts and graphs.
Step 4: Input Data into Excel
Use ‘Write Cell’ or ‘Write Range’ activities to input the retrieved data into the appropriate cells in your Excel template.
Step 5: Create Graphs in Excel
Use UiPath Excel activities to create graphs:
Use the ‘Excel Application Scope’ to open the Excel file.
Use the ‘Invoke VBA’ activity to run a VBA macro that creates graphs based on the data range.
Alternatively, you can pre-configure the Excel template with charts that automatically update when new data is entered.
Step 6: Save and Send Report
Save the Excel report.
Use the ‘Send Outlook Mail Message’ activity or other email activities to send the report to the stakeholders.
Detailed Steps:
Data Collection:
Use activities like ‘Execute Query’, ‘Read Range’, or web automation activities to collect the data for the current day.
Data Processing:
Sort, filter, and calculate the required data within UiPath using ‘Assign’ activities and store the results in variables.
Report Generation:
Open an Excel template using ‘Excel Application Scope’.
Populate the Excel file with the processed data using ‘Write Cell’ or ‘Write Range’.
If graphs are pre-configured to use the data range where you write the counts, they should update automatically. Otherwise, use ‘Invoke VBA’ to run a macro to create/update graphs.
Distribution:
Save the report.
Attach the Excel file to an email using the ‘Send Outlook Mail Message’ activity or another email activity and configure the recipients.
Here’s an example of how you might structure your workflow:
Execute Query (SQL database or application API)
Process results (Data Table manipulation)
Open Excel Template (Excel Application Scope)
Write Range (processed data)
Refresh/Create Graphs (Invoke VBA or pre-configured graphs)
Save Excel File
Send Email (Send Outlook Mail Message)
Make sure you schedule the UiPath robot to run at a specific time each day to generate and send the report automatically.